AltME groups: search
Help · search scripts · search articles · search mailing listresults summary
world | hits |
r4wp | 443 |
r3wp | 4402 |
total: | 4845 |
results window for this page: [start: 1701 end: 1800]
world-name: r3wp
Group: I'm new ... Ask any question, and a helpful person will try to answer. [web-public] | ||
PatrickP61: 17-Jul-2007 | Thanks Brian. I will play around with it a little more. Just to re-iterate my understanding of rebol assignments A variable is not evaluated when assigned - the value is, and then it is assigned to the variable. You don't really define" variables in REBOL" So at the time of assignment, the text following the : is assigned to the variable but is not evaluated. That is to say the variable is like a pointer to the text string that was typed in. Does that mean that Rebol will not do evaluations until it needs to. For example: In-file: %file_path_name.txt In-text: Read In-file write %out-file-path-name.txt In-text <-- this is where the evaluation occurs to resolve all the above? Is that right? | |
PatrickP61: 17-Jul-2007 | Another similar example: In-file: %file_path_name.txt In-text: Read In-file append In-text 'this-is-the-end-of-the-file <-- evaluated because of action word append write %out-file-path-name.txt In-text | |
PatrickP61: 19-Jul-2007 | Getting better, but still no cigar. Here is my test code for Mold-CSV function in CSV.r script: ( I hope this formats correctly on Altme) In-block: [ ; (want in csv file) ; (want in excel) ["Col A1" "Col B1" ] ; Col A1,Col B1 ; Col A1 Col B1 [2 3 ] ; 2,3 ; 2 3 ["'3" "'4" ] ; '3,'4 ; '3 '4 ["4a" "4b" ] ; 4a,4b ; 4a 4b ["^"5a^"^"^"^"" "^"^"^"5b^"^"" ] ; "5a""""","""5b""" ; 5a"" "5b" ["6a x" "6b y" ] ; 6a x,6b y ; 6a x 6b y ["7a, x" "7b,^"^" y" ] ; "7a, x","7b,"" y""" ; 7a, x 7b," y" ["^"8a ^"^",x" "^"8b ^"^"^"^"y^"" ] ; "8a "",x","8b """" y" ; 8a ",x 8b "" y ["^"^"^"9a^"^" x" "^"9b ^"^"y^"^"^"" ] ; """9a"" x","9b ""y""" ; "9a" x 9b "y" ] Out-block: Mold-CSV In-block write %Book2.csv Out-block ____________ In the above, I have 3 "views" if you will of what I am after. The first view is the In-block that I would like Mold-CSV to run against. The second commented view is what I need Mold-CSV to generate to put into the csv file The third commented view is what Microsoft Excel will generate when I open the CSV file. Mold-CSV works fine for the first 6 lines, then it gives me this for lines 7,8 and 9: 7a, x ,{7b,"" y} <-- Where did the braces come for for 7b? {"8a "",x},"8b """"y" <-- Same quest for 8a? 9a x ,"9b ""y""" ok Any ideas on how to solve this? | |
Anton: 19-Jul-2007 | I don't understand the exact logic of the CSV file quote formatting, but you could use a function similar to this: enquote: func [string][rejoin [{"} string {"}]] >> print enquote "hel^"lo" hel lo" and you could take it further by replacing single instances of " in the string with two instances, etc. | |
PatrickP61: 19-Jul-2007 | Anton, What do you think of this approach -- I'm just thinking it through and am not sure if I have covered all the bases. Since my input can contain any number of symbols, commas, single and double quotes, and rarely, but possibly braces, what if I attack the problem a different way. Whenever an embedded comma, or double quote or something like that occurs within an spreadsheet cell, it will require some kind of "extra" formatting like two quotes or the like. It may even be that there are unique combinations of such symbols, rare as that would be, to have complex formatting of an input block for rebol to convert it properly for CSV. What if I shift gears and look at a TAB delimited file instead. I know that I will never have TAB embedded in my cells, and that I deal with the entire block as a series instead. I could embed TAB wherever needed to separate the columns and leave the remaining string the way it is. Would that work, or would I still need to do some formatting to handle it. I think I'll open an excel spreadsheet, and work in reverse to see what it needs for TAB delimited file. Any comments? | |
PatrickP61: 20-Jul-2007 | For those of you monitoring and want to see what I mean: Out-string: [ ; (want in tab file) ; (want in excel) {Col A1^-Col B1^/} ; Col A1 Col B1 ; Col A1 Col B1 {2^(tab)3^(line)} ; 2 3 ; 2 3 {'3^-'4^/} ; '3 '4 ; '3 '4 {4a^-4b^/} ; 4a 4b ; 4a 4b {5a""^-"""""5b"^/} ; 5a"" """""5b" ; 5a"" ""5b {"""6a x"""^-6b y^/} ; """6a x""" 6b y ; "6a x" 6b y {7a, x^-7b," y"^/} ; 7a, x 7b," y" ; 7a, x 7b," y" {8a ",x^-8b "" y^/} ; 8a ",x 8b "" y ; 8a ",x 8b "" y {"""9a"" x"^-9b "y"^/} ; """9a"" x" 9b "y" ; "9a" x 9b "y" ] write %Book2.txt Out-string Aside from just need to insert a ^(tab) or ^- at the appropriate places to separate a cell from each other, and a ^(line) or ^/ in a string, I will also need to check the first character of each "cell". If it starts with a ", then I need to add another set around it. See 5b and 9a above to see what I mean. | |
PatrickP61: 20-Jul-2007 | My end goal is to be able to take some formatted text of some kind, something that is generated by a utility of some kind, and generate a spreadsheet from it. The formatted text can be of any type including " and the like. I'm working in reverse, by creating a spreadsheet in MS excel with various kinds of data that I've shown above. Some data with just alpha, just numbers, combinatins, leading quotes, trailing quotes, embedded quotes, embedded commas, spaces etc. Then I saved the spreadsheet as CSV and another version as Tab delimited. Then by looking at those files via notepad or other editor, I can see how the data must be in order for MS excel to accept it. I initially had problems with the CSV model because embedded qutoes needs other qutoes added to that "cell" if you will. The Tab delimited model has less restrictions on it. The only thing that needs attention is when a "cell" starts with a quote, which needs additional quotes added to it. Embedded qutoes or trailing qutoes don't need any modification. Long story short -- I'm going with Tab delimited model and figuring out a rebol script to take data from an IBM utility dump (with rules on what data to capture), and model that info into an excel spreadsheet via Tab delimited file. | |
PatrickP61: 20-Jul-2007 | Hi Gregg -- The cookbook recipe is a good one for reading and processing CSV's as input. My main issue is NOT the CSV part itself. It is pretty simple really. But as usual MS has some additional formatting rules whenever certain characters are embedded, and that is the part I'm having trouble with in order for a CSV file to be loaded as a spreadsheet. You don't happen to have one that lets you write CSV files as output for excel (with all the special rules etc)??? :-) | |
RobertS: 1-Aug-2007 | can you tell me why to-file does not care if a word holding the value of a file name is presented as | |
RobertS: 1-Aug-2007 | to-file :filename | |
RobertS: 1-Aug-2007 | or to-file filename | |
RobertS: 1-Aug-2007 | source to-file is very simple to-file: func [value] [ to file! :value ] ; which seems to apply : to a get-word! in the first case | |
RobertS: 1-Aug-2007 | ed: func [/file filename [string! file!] " afile name" /local fn ] [either file [either exists? fn: to file! :filename [editor fn] [fn: ask "file name: " editor to file! :fn] ] [editor {}] ] | |
RobertS: 1-Aug-2007 | comment { this works the same ed: func [/file filename [string! file!] " afile name" /local fn ] [either file [either exists? fn: to file! filename [editor fn] [fn: ask "file name: " editor to file! fn] ] [editor {}] ]} | |
Gregg: 1-Aug-2007 | >> logname: does [rejoin [now/date ".log"]] >> to-file logname == %1-Aug-2007.log >> to-file :logname == %?function? | |
RobertS: 1-Aug-2007 | what seems a little spooky is the way the behavior Gregg illustrates disappears when I define to-file as to-file: func [value] [to file! value] ; cool - or spooky | |
btiffin: 3-Aug-2007 | Carl wants such a list for form, mold, to string!, format (but that's R3), add the serial form, score some points and help the beginners in one grand pdf-maker datatype file. Not much to ask, is it John? :) | |
RobertS: 27-Aug-2007 | I have written an alternate form of the func WHAT that dumps to a file ( I have only 481 global functions at startup ) I will try to find time to build a page that gives clicks for SOURCE and HELP for each func in a given file dump (and maybe group them) I tried messing with PRINT but that broke HELP and SOURCE ;-) | |
Gabriele: 28-Aug-2007 | you can also just: echo %somefile.txt - everything that is printed also goes to the file. echo none disables it. | |
RobertS: 31-Aug-2007 | ; this now makes sense >> file: %image.jpg >> print copy/part file find file "." ; == "image" I will focus on this example in my tutorial but only AFTER >> fileName: "image.jpg" >> print copy/part fileName find fileName "." ; == "image" | |
RobertS: 31-Aug-2007 | ; I did a dif between the functions in VIEW and those in CORE for a default install. What I get is this ( I hope it is useful to have al 106 in one place ) alert brightness? caret-to-offset center-face choose clear-face clear-fields confine crypt-strength? dbug deflag-face desktop dh-compute-key dh-generate-key dh-make-key do-events do-face do-face-alt do-thru draw dsa-generate-key dsa-make-key dsa-make-signature dsa-verify-signature dump-face dump-pane edge-size? editor emailer exists-thru? find-key-face find-window flag-face flag-face? flash focus get-face get-net-info get-style hide hide-popup hilight-all hilight-text hsv-to-rgb in-window? inform insert-event-func inside? install launch-thru layout link-relative-path load-image load-stock load-stock-block load-thru local-request-file make-face notify offset-to-caret open-events outside? overlap? path-thru read-net read-thru remove-event-func request request-color request-date request-dir request-download request-file request-list request-pass request-text reset-face resize-face rgb-to-hsv rsa-encrypt rsa-generate-key rsa-make-key screen-offset? scroll-drag scroll-face scroll-para set-face set-font set-para set-style set-user show show-popup size-text span? stylize textinfo unfocus uninstall unlight-text unview vbug view viewed? win-offset? within? | |
Group: Make-doc ... moving forward [web-public] | ||
Vincent: 1-Apr-2005 | Robert : For the structure, you can look at my 'Easy-Doc prototype: http://rebol.dev.fr/view.php?sid=141 It works with 3 sets of modules: readers, parsers and writers. 'readers have to supply a text string to parsers (ie. MS-Word files are scanned for text), 'parsers build a block in intermediate format (there is a makedoc parser,) and 'writers output the result either in file or on screen (VID / html / pdf / rtf / swf). | |
Group: PDF-Maker ... discuss Gabriele's pdf-maker [web-public] | ||
Gabriele: 26-Sep-2006 | one possibilty would be: pass jpg file name, not image!; parse jpeg file for jpeg data; embed jpeg data in the pdf | |
Gabriele: 26-Sep-2006 | if compress does work, that could be applied to everything else too, so the resulting file would be surely smaller. | |
Maxim: 26-Sep-2006 | (embed jpg file saved from rebol and converted to jpeg with image-magic) | |
Gabriele: 29-Sep-2006 | hmm, rereading the spec, it may work just putting the jpg file there. i will try that, eventually. :) | |
Gabriele: 25-Nov-2006 | there's also the issue, that if we allow specifying a binary! instead of image! and interpert it as a jpeg file, then the dialect will have no default to use for the size, unless we go on and parse the jpeg header, or load the jpeg into a image! temporarily just to get its size. (binary! would have the added benefit to work also in Core, however that would only be for jpeg images) | |
Oldes: 3-Mar-2007 | and which windows encoding? Maybe can janeks just set some flag or something which specifies his encoding in the file. | |
amacleod: 19-Apr-2008 | Is a pdf file compressed or encrypted. Is there anyway to parse it? | |
amacleod: 8-Dec-2008 | How tuff would it be to parse out the image data from a pdf file...or for that matter, the text. Formating not important... Or does anyone know of a good lib or dll that does this? | |
Gabriele: 18-Dec-2008 | depending on how the PDF file is built, extracting text and images could be trivial, or very difficult. | |
Janko: 12-May-2009 | do you know anything about this http://www.tv.com.pl/stepbystep/pdfinclude/ .. I am trying by manually editing the pdf file but so far no changes | |
Janko: 12-May-2009 | in the pdf file ... I discovered one good news now ... I need csz ( like ch sh zh in eng) .. I saw that zh that I thought before doesn't have a glyph in standard fonts didn't make it to the generated pdf and if I add it by hand and update length of stream Zh works ... so now only Ch is the problem .. (because it's not represented in win1252 , the character with same code 200 in 1252 is E (arrow) È | |
Gabriele: 12-May-2009 | changing the pdf file directly will break it because the index at the end needs to point to all the objects in the file... so if objects move around the index needs to be redone. | |
Gabriele: 12-May-2009 | it's possible to edit the pdf file by appending stuff to it, but you'll need to read the specs to make that work, it's not entirely trivial either. | |
Maxim: 15-May-2009 | IIRC adobe is notorious for implementing the worst file formats possible. | |
Gabriele: 23-Aug-2010 | that is defined in the test-pdfm.r file where it says: text book [ .... ] | |
Graham: 24-Aug-2010 | this is the end of the file endstream endobj 8 0 obj << /Type /Pages /Kids [6 0 R] /Count 1 >> endobj 1 0 obj << /Type /Catalog /Version /1.4 /Outlines 2 0 R /Pages 8 0 R >> endobj 2 0 obj << /Type /Outlines /Count 0 >> endobj 3 0 obj [/PDF /Text /ImageC] endobj xref 0 9 0000000000 65535 f 0000005180 00000 n 0000005259 00000 n 0000005305 00000 n 0000000009 00000 n 0000000111 00000 n 0000000208 00000 n 0000000414 00000 n 0000005123 00000 n trailer << /Size 9 /Root 1 0 R >> startxref 5341 %%EOF | |
Group: AGG ... to discus new Rebol/View with AGG [web-public] | ||
shadwolf: 21-Jun-2005 | I use inkscape to make new-file.svg and this one doesn't load at all | |
shadwolf: 21-Jun-2005 | I think taking as dev reference my file new-file.svg made with Inkscape is a good start point (this image is simple but a good sample of what we need to support :) | |
Ashley: 22-Jun-2005 | Pekr: the SVG Demo is just a quick and dirty prototype. I'm just going to get it to the stage where it can display simple SVG icons (for RebGUI). If someone else wants to write an SVG viewer that is fully SVG 1.1 (with 1.2 around the corner) compatible then good luck ... I'm *not* going to be doing that! ;) yeksoon: see above comments. I'm tweaking the SVG Demo code on an SVG icon by icon basis. As long as it works for the icons I use (or intend to use) I'm happy - I don't guarantee the code will work with anything other than the specific SVG files I have tested it on. Cyphre: SVG is such a "flexible" standard isn't it? :) One question; how did you map SVG "path d" commands (e.g. <path style=... d="M 10 10 C 20 20 ... z") where there is no "z" command to close the "shape" (i.e. the AGG shape command closes by default). shadwolf: Having our own SVG icons is a good idea as we don't have to worry about licence / distribution issues and we can tweak the generation to make it as AGG compatible as possible. To do that we need to settle on *one* tool so as we generate consistent SVG code, and we should generate SVG that uses a single unit of measure, preferably pixels, as it's a real pain trying to handle multiple units of measure within the same file. I'll continue this discussion in the RebGUI group. | |
shadwolf: 22-Jun-2005 | I think trying to arrive to the level to inkscape in our own SVG DRAW MAKER software will take more than one year to redone it with REBOL... So to avoid loss of time we can yet work on the engine for rebgui feeting to InkScape SVG format then we can start working to our own SVG DRAW MAKER made in full REBOL... One thing that afraid me a little is the flexibility of the SVG format as it can be very different how to support any SVG file comming from any EDITOR ? For me SVG appears to me to be close to what we done with MakeDoc format. Today we have many MD like format all very good but to make a Viewer in rebol that support them all it wil be very very difficult. | |
shadwolf: 22-Jun-2005 | take my file fraisier.jpg and draw it the same translating it to VID Draw AGG dialect you will see that it's afull too (take left space i'm agree ...) | |
shadwolf: 22-Jun-2005 | what is more easier and productiv (sorry but if you spent 3 weeks to draw the logo of your website in DrawAGG commands you will be fired and that's all) Making a description of your image in pure draw dialect ? Making it in SVG using a SVG Drawer editor then integer it to a VID renderer to have the snapshot ? And then if your boss or client found that the produced graphic doesn't complity to his thought how difficult would it be to modify it in AGG code (pure texte no graphical editor) in SVG (there you have an editor and you can retake the file and then modify it very easyly ) or in bitmap once produced it's very hard to modify (a part if you save it into an intermediate format ? ) | |
shadwolf: 22-Jun-2005 | 20 years ago Wav and Midi format where the only ones now in day you have more than 10 sound encoding format .... An alternative could be to traslate systematically the what ever encoded sound file to a WAV one and then play it but franckly do you thing people that are using a jukebox software (like winamp for example) will accept 1) to wait 5 minutes for theire files to be translated then have a poor audio quality ??? | |
shadwolf: 22-Jun-2005 | Pekr imagine you compose you graphics with inkscape (SVG editor very complete and free) then you set your animation process with AGG and then you put it online in your site. People come along in you web site make the click on the link to you new file then rebol/view plugin launch and run you SVG graphics with you AGG animation. In front of that you have flash sure but flash is made by a specialised in the grpahic industry company and not by a generic company ;) | |
Group: Web ... Everything web development related [web-public] | ||
Graham: 9-Oct-2005 | I must be doing something wrong in creating my tex file. | |
Robert: 2-Nov-2005 | Question: Has anybody written a log-file analyzer tool in Rebol? I really must say, that I have looked into a lot of those tools but never found a good one. All spit out some information but not the one I'm mostly interested in. And I just get reports but can't do any trend analyzes etc. | |
Oldes: 13-Feb-2006 | yes, no problem, and the issue with the bots - if the bot don't support cookies (non of them does), i can give him whatever I want, I'm not cheeting, I just may think, that it's somethink like LYNX and serve him pure text pages:) And if he don't like it so it's his problem (or its?) And with the robot.txt file - ugly bots will not respect robot.txt file anyway :) | |
Oldes: 5-Apr-2006 | I need to post file with field data from console | |
james_nak: 5-Apr-2006 | REBOL [ Title: "Http tools" Date: 14-Dec-2000 Version: 0.0.3 File: %http-tools.r Author: "Graham Chiu" | |
Oldes: 5-Apr-2006 | Hm. it should be: read/custom url [multipart [file %test.r name "test"]] (because I need field name for the file as well:-) | |
Oldes: 5-Apr-2006 | !!! Cookies-daemon script now allows to post data as a multipart !!! do http://box.lebeda.ws/~hmm/rebol/cookies-daemon_latest.r ;sending single file: read/custom target-url [multipart [myfile %somefile.txt]] ;== same like <INPUT TYPE=FILE NAME=myfile> ;sending normal fields: read/custom target-url [multipart [field1 "some value" field2 "another value]] ;sending multivalue: read/custom target-url [multipart ["field[]" "some value" "field[]" "another value]] ;sending file with field value: read/custom target-url [multipart [myfile %somefile.txt field1 "some value"]] Source files (with modified %http-patch.r) are in this archive: http://box.lebeda.ws/~hmm/rebol/cookies-daemon_latest.rip As it's part of the cookies-daemon, it should deal with the cookies automatically. The script is trying to detect content-type of the file which you want to upload calling get-content-type function, which is not part of the cookies-daemon (at this moment) | |
Louis: 26-Apr-2006 | That doesn't work either. There must be something wrong with the file itself. | |
Maxim: 26-Apr-2006 | maybe it crapped out while transfering, try copying the file again? | |
Louis: 26-Apr-2006 | Maxim, you are right, the file is corrupted during transfer. Thanks! | |
Anton: 26-Apr-2006 | The server just serves files. It should not care what they contain. You can check if the file completed with: probe info? http://www.myserver.com/path/to/your.jpg to see if it has the right size, at least. | |
Louis: 19-Sep-2006 | Due to a very slow Internet connection, I need to make the FTP module of my website builder script more efficient so I don't send files unnecessarily. What I have in mind is: 1. Delete all the files in the website directory on my harddrive to eliminate all unused files. 2. Build the website to the website directory on my harddrive. 3. Download a list of the file names and creation dates from the website (all are in one directory). 4. Read the list of file names and creation dates from the directory on my harddrive (all are in the one directory mentioned in 2 above). 5. If a file is on the hard drive but not on the server, send it to the server. 6. If a file is on the server but not on the harddrive, delete the file on the server. 7. If a file on the harddrive is newer than a file on the server, send it to the server. Has anyone already done this? Am I forgetting anything? Any pointers on how to do this? | |
MikeL: 19-Sep-2006 | Sorry about the CRLF ..... you don't want to be checking the timestamps on the server with a slow connection. Just hold the last updated value locally and if it changes then transfer the file. Same for deleting ... else you spend all of your time checking on the server over a slow connection. You could check the timestamps or hash the local value ... then if the hash value of the source changes, transfer the updated version. There's some code to do some of this in build-sie.r http://www.rebol.org/cgi-bin/cgiwrap/rebol/view-script.r?script=build-site.r but it's a rebol-ish task. | |
Louis: 19-Sep-2006 | Graham, if a file upload fails somewhere in the middle, will you script restart the upload where the failure occurred so that the first half of the file does not have to be downloaded again? | |
Sunanda: 20-Sep-2006 | Louis -- a couple of pointers about uploading files to a server using a slow FTP connection: (I do it myself with REBOL.org -- most of the development takes place on my machine and is uploaded to RO via a 56K modem, so this is based on real experience.) -- If you are uploading a large live file, that file will be available and/or "broken" during the course of the upload. Best to upload with a temporary file name, and then rename when uploaded. -- That won't work with CGI scripts under Apache/UNIX as the rename won't leave them with the right file permissions to execute. But it will work for all other files, including scripts that are DOne by your CGIs. -- We have a checksums file that the uploader uses. Before uploading a file, it checks the file's upload checksum. That way, we only ever upload new or changed files. | |
Janeks: 23-Oct-2006 | I had faced with problem for file uploads: I had file upload script (upload.r posted somwhere in rebol lists/worlds) on my web servers, that works well on KF web server. But on MS IIS script hangs and I am getting timeout error from server. If it is needed I can post upload.r here! | |
Gabriele: 7-Nov-2006 | the simplest way, which however needs write permissions to the filesystem, is to have a unique session id assigned to users; this id could be basically a file name (and you need to check for its sanity then); then you read from the file at the beginning, and save to it at the end. | |
Gabriele: 7-Nov-2006 | eg. you could have session: load session-file at the beginning; then your script does whatever with session; then you save session-file session at the end. | |
Sunanda: 18-Dec-2006 | Thanks C. It is really easy isn't it? The main differences between your approach and mine that I can see are: 1. you hold all data in one file; mine uses one file per session 2. you create just a cookie; mine creates a session record in which the CGI script can save data Either way, the scripts demonstrate that the problem is really trivial -- with the one need to create unique and hard-to-guess session ids. We've both put some serious code into doing that. | |
Oldes: 16-Jan-2007 | the problem is, that if you are posting large file, it's not too good, as all file is first uploaded again and than you can decide, if you want it to store for example. I though I sow something, but maybe it was just a fata morgana, I thing, that the best is the redirect. My problem is, that I'm trying to connect on database, which was not designed by me, so there is no crypted id for the data I upload, just incremental integer, which I don't want to use, as I would give chance to everybody go thru the data just inserting other numbers. I have to take a risk, modify the original database adding ne column with crypted id and redirect to the uploaded data using this id. And hope, that I will find and modifie all places, where is this database used:( | |
DanielSz: 9-Nov-2007 | Hi, I'm looking into Chris' emit-rss.r script, however, when I run the usage example provided in the header, all I get in the my-feed.rss file is this: No Item Author Details - "Journal Entry title...." I believe it is used on Carl's blogs, so I'm surprised, it should be working. Thanks in advance for any valuable clues...1 | |
DanielSz: 9-Nov-2007 | REBOL [ > Title: "RSS Generator for Carl's Blog" > Date: 31-Dec-2004 > File: %carl-rss.r > Home: http://www.livejournal.com/~premshree > Author: ["Premshree Pillai" "Gregg Irwin"] > Version: 0.0.3 > Purpose: {Generate valid RSS 2.0 feeds for Carl's blogs} > Comment: { > 0.0.2 Massive code changes for instructional purposes. --Gregg > 0.0.3 More changes, knowing Carl actually wants to use it. :) --Gregg > } > ] | |
Anton: 3-Mar-2008 | Aha ! Tracked it down. In my frame I had a BASE tag. This caused the javascript error: Error: document.getElementById("navList") has no properties Source File: javascript:alert('width: ' + document.getElementById('navList').offsetWidth); <html> <head> <base target="_top" /> </head> <body> <ul id="navList" > <li>Hello</li> </ul> <a href="javascript:alert('width: ' + document.getElementById('navList').offsetWidth);">navList width</a> </body> </html> | |
Will: 2-May-2008 | here is a more complete example that will save url of all browser windows to a file: http://daringfireball.net/2003/02/save_and_restore_safari_urls | |
Robert: 6-Aug-2008 | I'm searching for a good free log-file analyzer (whatever that means ;-)). Any hints? I know: - Analog - Webializer But both are not that good IMO. | |
DideC: 14-Jan-2009 | Then, when this script runs well, put the same sheeband at the beginning of the magic.cgi file. | |
DideC: 14-Jan-2009 | Then I have a file test.rhtml (handler for .rhtml must be configured in the webserver) with this content to test magic : | |
PeterWood: 18-Jan-2009 | Alan From your posting on the Rebol-France BB, it looks as though the formattng of your AddHandler declarations in your httpd.conf file are not correct. I use these: AddHandler cgi-script .cgi AddHandler cgi-script .r #Following entry added to enable Magic! AddHandler magic .rhtml Action magic /magic/cgi-bin/magic.cgi | |
Janko: 11-Feb-2009 | do you have a domain name assigned to your computer? if it is then you can access it as anybody else ... I am not sure I understand ... if you have a virtual host set and you want to test if it works (and are on windos) you can add www.yourdomain.com to hosts file in winnt/system32/drivers | |
Oldes: 11-Feb-2009 | If you are on windows, check c:\WINDOWS\system32\drivers\etc\hosts file | |
Ashley: 2-Apr-2010 | Code snippet to "inline" an image: string: trim/lines form read/binary file remove back tail string ajoin [{<img src="data:image/} next suffix? file ";base64," skip string 5 {">}] Adds about 30-50% to image size but reduces server fetches (important for wireless access). | |
Ashley: 3-Apr-2010 | Ah, even simpler then: ajoin [{<img src="data:image/} next suffix? file ";base64," enbase read/binary file {">}] Thanx. | |
Will: 3-Apr-2010 | and obviously you can have all the image data in a javascript file as well (for which you probably already have a longer cache expire set up) | |
Gabriele: 28-Aug-2010 | In my approach, the mapping between the data and the "view" is defined by a dialect. I guess, one might want to make at least part of that mapping part of the view; this does not change the fact that the template file can then be simple HTML. Formatting to me does not seem a templating issue though. It's about localization and customization (different users will want different formats for dates, and almost everything else). So, this is a completely separate axis. As Carl often says... the problem is multidimensional, reducing it just to "model" and "view" is not really going to work. | |
GrahamC: 7-Nov-2011 | From 2003 ... the header dialect might work now though since the article was written http://www.compkarori.com/vanilla/display/HTTP+file+uploading | |
Group: Announce ... Announcements only - use Ann-reply to chat [web-public] | ||
Graham: 14-May-2006 | http://www.compkarori.com/reb/download-manager.r is a wrapper around Anton's batch download script. It reads a configuration file(s) from a site and loads the data into the script. This is as: file description url and then extended file description. Defaults are embedded into the script and are used if the read fails. You can use it to download iso files etc. | |
Graham: 14-May-2006 | Any urls in the extended file description are clickable. | |
Ladislav: 13-Sep-2006 | there is a zip file containing everything | |
Louis: 19-Sep-2006 | rebol [ Title: "Stopwatch" Date: 23-Mar-2005 Version: 1.0.0 File: %stopwatch.r Author: "Louis Turk" Purpose: "Simple desktop stopwatch." ] kbhit: does [ con: open/direct/binary/no-wait console:// until [wait con] choice: to-char pick con 1 close con choice ] forever [ prin "Hit any key to start: " kbhit start-time: now/time/precise print [start-time] prin ["Hit any key to stop : "] kbhit end-time: now/time/precise print [end-time] print [newline newline end-time - start-time newline newline] ] | |
Louis: 19-Sep-2006 | rebol [ Title: "Stopwatch" Date: 19-Sep-2006 Version: 2.0.0 File: %stopwatch.r Author: "Louis Turk" Purpose: "Simple desktop stopwatch." history: "v.2 works across midnight thanks to Gabriele" ] kbhit: does [ con: open/direct/binary/no-wait console:// until [wait con] choice: to-char pick con 1 close con choice ] forever [ prin "Hit any key to start: " kbhit start-time: now/precise print [start-time] prin ["Hit any key to stop : "] kbhit end-time: now/precise print [end-time] print [newline newline difference end-time start-time newline newline] ] | |
Louis: 11-Oct-2006 | REBOL [ Title: "Slideshow" Date: 12-Oct-2006 Name: 'SLIDESHOW ; For window title bar Version: 1.0.0 File: %slideshow.r Author: "Louis A. Turk" Rights: "Public Domain; use at your own risk." Needs: "A version of REBOL/VIEW supporting sound" Purpose: {To make possible simple, easy to make narrated slide shows. Hopefully can be used with the REBOL plugin to show narriated slides on a web site. Hopefully can an effective tool to teach REBOL programming. } Note: { The concept and design originated with Louis A. Turk. DideC helped considerably by answering programming questions and giving bits of code; it would not have been possible without his help. Josh also answered programming questions. You can make wav files using the free program Audacity. http://audacity.sourceforge.net Advanced JEPG Compressor does and excellent job compressing graphics files so they load faster, but is not free. } History: [ 1.0.0 [ "First release." "Louis"] ] Language: 'English ] ;Requires a data file named %slides.r containing lines of blocks in the following format: ;Each block must contain: (1) slidename, (2) overlay, (3) caption, (4) sound. ;Example block: [%slide1.jpg "Overlay text." "A caption!" %sound.wav] ;Use "" for no overlay or caption. ;file: request-file/title/only "Select the slides data file to use." "Select Data File" file: %slides.txt ;uncomment the above line, and comment this one to select data files with different names. slides: load file narrate: func [talk] [ ;--- Manage the sound sound-port: open sound:// insert sound-port load talk wait sound-port close sound-port ] view/new win: layout/size [] 650x650 ;<= Set the max size you need wait 0 ;---Initialize REBOL's internal event handler. foreach slide slides [ ;--- Start the slide show set [graphic overlay caption narration] slide lay: layout [ origin 0 banner center bold red "A REBOL Produced Narriated Slide Show" image graphic overlay 500x400 frame black [unview] [quit] text 500 bold caption button "Quit" center [quit] ] center-face/with lay win append clear win/pane lay show win narrate narration ] do-events | |
Group: DevCon2005 ... DevCon 2005 [web-public] | ||
JaimeVargas: 1-Sep-2005 | Yes. You need to publish the sdp file. | |
BrianH: 22-Sep-2005 | I was talking about the MP4 container format. We were talking about portable formats, right? H.264 in Quicktime requires version 7, which is still a little shaky on Windows, and absent on Linux. MP4 doesn't require Quicktime, even if the standard file format is still a derivative of an older version of the Quicktime file format. | |
Group: rebcode ... Rebcode discussion [web-public] | ||
Oldes: 25-Nov-2005 | ech 10MB of download just to read a simple text file, I'm not going to read it today. | |
Henrik: 2-Apr-2006 | Console: 0:00:12.979 - 39 KC/S Processor: 0:00:00.801 - 1078 RHz (REBOL-Hertz) Memory: 0:00:02.023 - 23 MB/S Disk/File: 0:00:00.991 - 30 MB/S | |
Robert: 3-Apr-2006 | Hey, that's cool. I get 33.3 FPS. Console: 0:00:01.082 - 467 KC/S Processor: 0:00:00.501 - 1724 RHz (REBOL-Hertz) Memory: 0:00:01.091 - 43 MB/S Disk/File: 0:00:00.471 - 64 MB/S | |
Jerry: 21-Oct-2006 | REBCODE is AMAZING ... I am trying to convert a 300+ MB file from little-endian 16-bit Unicode to UTF-8. I am pretty sure that all the characters in this file are ASCII characters, so I can just discard the second byte (0x00) of every 16-bit Unicode character. Beside that, the beginning 2 bytes (0xFFFE) need to be discard too. In these two days, I wrote REBOL scripts for this purpose in different ways, and I suffered in different ways, too. Sometime I got out-of-memory error, sometimes I didn't. Even if I didn't get any error, the performance would definitely dramatically dropped down after few minutes because of the memory issue, I guess. I would take me 30 minutes to convert the file in my PC. I was trying to make it less than 10 minutes, so I kept asking stupid questions in the AtlME REBOL3 World. Few ours ago, REBCODE came to my mind out of the blue. I remembered Carl said something like 10-30 faster. Because I am no REBOL expert, I'd never used REBCODE before. I took 1-2 hours to read the REBCODE document, then I do my very first REBCODE code in my life. Guess what? It turned out very well. The REBCODE version took only 45 seconds. It's AMAZING. | |
Henrik: 27-Feb-2007 | steeve, you could probably make your file even smaller by enbasing the game rom in source. | |
Group: !REBOL3-OLD1 ... [web-public] | ||
Anton: 11-Apr-2006 | net-utils/net-log join "Type: " type: any [ all [new-dir? 'new-dir] all [new? 'new] all [dir-read? port 'dir] all [port/state/flags and system/standard/port-flags/open-append <> 0 'app] 'file ] do select [ file [ confirm-cmd port either port/algorithm = 'nlst [nlst-check] [list-check] accept-connect port type parse-dir-list port if tmp: select locals/dir-cache to-file port/target [ port/status: first tmp port/date: third tmp if any [none? port/size: second tmp 1024 > port/size] [port/size: 0] ] data-connect port confirm-cmd port binary-type-check if 0 < cmd-port/state/index: port/state/index [ confirm-cmd port restart-check ] confirm-cmd port read-check ] new [confirm-cmd port write-check] new-dir [confirm-cmd port mkdir-check] dir [confirm-cmd port either port/algorithm = 'nlst [nlst-check] [list-check]] app [confirm-cmd port append-check] ] type accept-connect port type if type = 'dir [ port/size: port/state/tail: parse-dir-list port ] ] port ] close: func [port /local cmd-port cache-size][ cmd-port: port/locals/cmd-port if not dir-read? port [error-try? [confirm-transfer port]] net-utils/net-log reform ["Caching cmd-port" cmd-port/host cmd-port/local-port cmd-port/remote-port] cmd-port/host: cmd-port/locals/tuple | |
Maxim: 14-Apr-2006 | in the best of worlds I'd prefer it if we could read all the info from a .h file and convert it into a rebol file ready to load the dll... Gregg, Do you think this is possible? | |
Maxim: 14-Apr-2006 | I did a .h file parser a long way back... it was able to find and extract function names... but did not tackle the structs.... | |
Anton: 15-Apr-2006 | I made a .h header file parser, which handled function names, typedefs, structs, and enums. It was made specifically for FMOD and FMOD EX libraries, but it is pretty general, able to be tuned for other libraries "fairly" easily. Swig is probably the ultimate way, though it's not as easy as it sounds on the cover, and you might lose associtated documentation found in comments next to functions, struct elements etc. | |
Maxim: 20-Apr-2006 | how can I garantee loaded code is safe? ITS IMPOSSIBLE once you say OK to file I/O | |
Volker: 20-Apr-2006 | create a file and check ownership? does get-modes tell? |
1701 / 4845 | 1 | 2 | 3 | 4 | 5 | ... | 16 | 17 | [18] | 19 | 20 | ... | 45 | 46 | 47 | 48 | 49 |