alright, l have about 20 .txt files l wrote, l am really lazy and don't want to apply formatting to all of them (yes, l know that copy paste is really easy, and there are tools that will add something to the beginning and end of each document, but hey, l'm lazy, so none of that
). So, is there a way that l can get them to show, maybe like a flash type of thing, where it will import the .txt file when called upon. This may be the wrong forum, but hey, they broke up the scripting forum, so l post in here, someone point me to the right place, and l re-post there or a MOD moves, whatever
. But l would really like to know a way l can set a specific area in a flash and have a language call a .txt document there.
importing a .txt
import into waht?
| KHO wrote: |
| alright, l have about 20 .txt files l wrote, l am really lazy and don't want to apply formatting to all of them (yes, l know that copy paste is really easy, and there are tools that will add something to the beginning and end of each document, but hey, l'm lazy, so none of that |
| Code: |
| <pre><? include("/path/to/my/textfile.txt"); ?></pre> |
you mention using flash in which case I found what seems to be a good tutorial on the topic
http://www.webthang.co.uk/Tuts/tuts_fmx/d_flash2/d_flash2.asp
otherwise were all just sort of throwing ideas as to what you want to import it into as you havent said, unless thats what you wanted?
http://www.webthang.co.uk/Tuts/tuts_fmx/d_flash2/d_flash2.asp
otherwise were all just sort of throwing ideas as to what you want to import it into as you havent said, unless thats what you wanted?
| mathiaus wrote: |
| you mention using flash in which case I found what seems to be a good tutorial on the topic
http://www.webthang.co.uk/Tuts/tuts_fmx/d_flash2/d_flash2.asp otherwise were all just sort of throwing ideas as to what you want to import it into as you havent said, unless thats what you wanted? |
| KHO wrote: |
| otherwise were all just sort of throwing ideas as to what you want to import it into as you havent said, unless thats what you wanted? |
Delayed April Fools joke. You can disable it here;
http://www.frihost.com/forums/rainbox.php?mode=disable
You definently want to check out the AJAX technology XMLHTTPRequest. It can import txt, xml, or just about anything else into an empty element (div, span, ect.). Works well and you can find tutorials on it everywere. Apple has a really great one here: Apple XMLHTTPRequest. Try it out.
-Gabe
-Gabe
PHP is probably the better of all these methods though, because no matter what browser you're using (and regardless of whether or not you have JavaScript disabeled), it will always show up.
| KHO wrote: |
| alright, l have about 20 .txt files l wrote, l am really lazy and don't want to apply formatting to all of them (yes, l know that copy paste is really easy, and there are tools that will add something to the beginning and end of each document, but hey, l'm lazy, so none of that |
You can copy paste it to flash, with Macromedia Flash MX or oder versions
of it...
Related topics
