| | |||||
| ||||||||
| Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics. |
![]() |
| | LinkBack | Thread Tools |
| | THREAD STARTER #1 (permalink) |
| Senior Member Join Date: May 2005 Location: Ontario Canada
Posts: 3,088
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | javascript include? hey u know how u can include files using php command <?php include("http://www.url.com"); ?> is there a way of including files [or showing the content of the file..same thing] in JAVASCRIPT?
__________________ |
| |
| | #3 (permalink) |
| Senior Member Join Date: Jul 2005 Location: NJ
Posts: 1,219
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | well that wud just run the code of the javascript on the page, but i think what unknown is looking for is a way to use the include function without any php, so that he can have text documents "echo"ed in html pages. i dont know of any way to do this, unelss of course you somehow make it into a variable and then call the variable... but that mite get complicated. and javascript can get buggy esp. when ppl have it deactivated lol
__________________ Hacksar.com - Your source for random computer tips and tricks! MySiteMemberships.com - Keep track of your site registration information! Like my post? Rep is appreciated! |
| |
| | THREAD STARTER #4 (permalink) | ||||
| Senior Member Join Date: May 2005 Location: Ontario Canada
Posts: 3,088
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Code: <script type="text/javascript" src="http://nameprince.com/ads/showad.html"></script>
__________________ | ||||
| |
| | #5 (permalink) |
| NamePros Legend Join Date: Dec 2005 Location: Philippines - www.Nabaza.com
Posts: 19,785
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | the js include code only works on .js as well, let me see.. yeah it's js include all right you need to place your .html content in document.write on your .js file. there's another way .js and DOM here's some outside readings: http://www.quirksmode.org/js/placejs.html http://www.merlyn.demon.co.uk/js-nclds.htm if you want to include .htm files within .htm you might want to explore usage of SSI http://www.javascriptkit.com/howto/ssi2.shtml ????: NamePros.com http://www.namepros.com/showthread.php?t=210737 hth
Last edited by weblord; 06-25-2006 at 08:40 PM.
|
| |