473,706 Members | 2,577 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

SSI alternative

hi all,

my ISP doesnt support SSI and therefor i try to javascript to get the
same think done. the function i am interested in is ssi include virtual
and after some searching i found many times the same anser; use:

<!--
document.write( " your HTML here ");
// -->

now the problem is that it only works when all HTML is put in 1 line !
and this line cannot be longer than about 255 characters.

i am working on a winXP machine and have tried to use a unix-like-editor
(breakline thing) but still the same thing.

question: do i do something wrong or how to get it working ??

many thanks for helpful replies,

martin
Jul 23 '05 #1
5 1800
"Ali Babba" <Al******@40Ban dits.com> wrote in message
news:cv******** **@news.hispeed .ch...
hi all,

my ISP doesnt support SSI and therefor i try to javascript to get the
same think done. the function i am interested in is ssi include virtual
and after some searching i found many times the same anser; use:

<!--
document.write( " your HTML here ");
// -->

now the problem is that it only works when all HTML is put in 1 line !
and this line cannot be longer than about 255 characters.

i am working on a winXP machine and have tried to use a unix-like-editor
(breakline thing) but still the same thing.

question: do i do something wrong or how to get it working ??

many thanks for helpful replies,

martin


First omit "<!--" and "-->" as they're obsolete then change

document.write( " your HTML here ");

to:

document.write( " your");
document.write( "<br>HTML") ;
document.write( "<br>here ");

or:

var html = [
"your",
"HTML",
"here"];
document.write( html.join("<br> "));
Jul 23 '05 #2
Ali Babba wrote:
my ISP doesnt support SSI and therefor i try to javascript to get the
same think done.


Stop! Backpedel!

Including content using JavaScript is usually not a good idea. It will be
invisible for the not-insignificant proportion of the world which does not
have JS available and enabled (including GoogleBot).

You can achieve the effects of SSIs using an HTML preprocessor as described
at http://www.allmyfaqs.com/faq.pl?Incl...ile_in_another

--
David Dorward <http://blog.dorward.me .uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is
Jul 23 '05 #3
McKirahan wrote:
"Ali Babba" <Al******@40Ban dits.com> wrote in message
news:cv******** **@news.hispeed .ch...
hi all,

my ISP doesnt support SSI and therefor i try to javascript to get the
same think done. the function i am interested in is ssi include virtual
and after some searching i found many times the same anser; use:

<!--
document.writ e(" your HTML here ");
// -->

now the problem is that it only works when all HTML is put in 1 line !
and this line cannot be longer than about 255 characters.

i am working on a winXP machine and have tried to use a unix-like-editor
(breakline thing) but still the same thing.

question: do i do something wrong or how to get it working ??

many thanks for helpful replies,

martin

First omit "<!--" and "-->" as they're obsolete then change

document.write( " your HTML here ");

to:

document.write( " your");
document.write( "<br>HTML") ;
document.write( "<br>here ");

or:

var html = [
"your",
"HTML",
"here"];
document.write( html.join("<br> "));


thanks alot !! of course it works.
also thanks to david, although i stick with this solution.
Jul 23 '05 #4
On Fri, 18 Feb 2005 18:08:47 +0100, Ali Babba <Al******@40Ban dits.com>
wrote:
now the problem is that it only works when all HTML is put in 1 line !
and this line cannot be longer than about 255 characters.


I've never known any browsers with a 255 character limit, could you
provide more details of where you worked out the limit?

Jim.
Jul 23 '05 #5
Jim Ley wrote:
On Fri, 18 Feb 2005 18:08:47 +0100, Ali Babba <Al******@40Ban dits.com>
wrote:

now the problem is that it only works when all HTML is put in 1 line !
and this line cannot be longer than about 255 characters.

I've never known any browsers with a 255 character limit, could you
provide more details of where you worked out the limit?

Jim.


255 was a guess, and not a good one.

i was using windows notepad, and it has apparently somewhere a limit on
the number of characters in 1 line.

just checked with a better editor and i didnt get any weird behaviour
until i arrived around 40k charcters in 1 line.
Jul 23 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

46
4042
by: Robin Becker | last post by:
It seems that the rotor module is being deprecated in 2.3, but there doesn't seem to be an obvious alternative. I'm using it just for obfuscation. It seems we have ssl available in 2.3 for sockets, but there seems no obvious way to use that from python code. Is an alternative to rotor planned? -- Robin Becker
99
4639
by: Paul McGuire | last post by:
There are a number of messages on the python-dev mail list that indicate that Guido is looking for some concensus to come from this list as to what *one* alternative syntax for decorators we would like him to consider in place of the @ syntax that is currently in 2.4a2. I think special thanks are due to: - Anthony Baxter for his continuing efforts in this regard - Steven Bethard for some of the clearest thinking and writing on this topic...
28
2384
by: Paul McGuire | last post by:
Well, after 3 days of open polling, the number of additional votes have dropped off pretty dramatically. Here are the results so far: Total voters: 55 (with 3 votes each) Votes for each choice or group of choices: Any J 81 J2 78 Any C 40 C1 29 Any D 9
1
4822
by: Bob Smith | last post by:
so is there any alternative ( standard only ) to using in_avail()? I need to poll with given intervals the input stream, and if there is data to be read I want to read it. thank you /B
43
42803
by: Dimitri Debruyne | last post by:
Hi group I am in the process of developing a website in XHTML Strict and CSS. Is there a way to open a link in a new window without the use of frames or Javascript or something ? I didn't find a way ... TIA
4
2141
by: tonyz.wrightz | last post by:
Hi, I have used the setup wizard to build an installer that installs my asp.net application. Problem is, at my current job, they have an alternative web folder at the root level (to clarify, at the Default Web Site level, there is also another Web Folder). When I run the installer, it only wants to install the site under the Default Web Site, and doesn't appear to have any way of selecting the alternative location.
1
13305
by: prasaddevivara | last post by:
I am using the outerHTML property to modify the HTML of existin elements in a web page in Internet Explorer. But same outerHTM property is not working in firefox browser, Anybody can tell me a alternative for outerHTML property in firefox. I am using th following function to display an image and alternate text behind al images of a weg page in Internet Explorer. Anybody can give solutio for same in firefox browser. function...
3
2602
by: Will McGugan | last post by:
Hi, Is there a naming convention regarding alternative constructors? ie static methods where __new__ is called explicity. I use lower_case for methods in general, but thought maybe CamelCase would be better for alternative contstructors to distinguish them from methods... So which is better? c = Color.FromHtml(r, g, b)
0
2796
by: sachintandon | last post by:
Hello all, Thanks in advance for your help I have a problem in sending emails, my requirement is to send multipart alternative emails with attachments, I'm able to send text with attachments or HTML mails with attachments, but some mail clients are not able to display the html mails that is why I need to send multipart alternative emails, when I used multipart/alternative then I'm not able to send attachments and if I use the multipart/mixed...
11
2296
by: Francine.Neary | last post by:
I've read that as well as "normal" Java-like function definitions, e.g. int main(int argc, char **argv), you can also choose to use an alternative syntax, i.e. int main(argc, argv) int argc; char **argv; { .... }
0
8773
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9276
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9042
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8983
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6613
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5935
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3141
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2495
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2084
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.