/    Sign up×
Community /Pin to ProfileBookmark

plain text vs java

My title is probably wrong… (help me retitle this)
since im a newbie to javascript…

what i want is:
a way to get “plain text” from a script without using <script>…</script>
why i want this :
user side environnement doen’t support script.

Let me explain :
i will have 2 files ( main.html : 100% html no script , child.html :the script )
it means the script must run server side…

so, on user side, it will look like this :

source : main.html :
…</HEAD><BODY>mytext</BODY></HTML>

source : child.html :
…all my javascript are here…

Thanx in advance

to post a comment
JavaScript

5 Comments(s)

Copy linkTweet thisAlerts:
@wdsueauthorFeb 05.2010 — P.S. child.html will not be visible on user side.

---can this be achieved, just need a snippets or link to tutorials.

THX
Copy linkTweet thisAlerts:
@FangFeb 05.2010 — user side environnement doen't support script[/QUOTE]How do you expect the child window script to run?
Copy linkTweet thisAlerts:
@wdsueauthorFeb 05.2010 — ... hmmm...

may be php ?? ( instead of html )

i need "<script>document.write(StreamInformation.SONGTITLE())</script>"

to be converted to plain text before being send to browser.
Copy linkTweet thisAlerts:
@Declan1991Feb 05.2010 — Use a server-side language is your only option. However, since you are not telling us what you have to write out, or where it's coming from, I can't tell you if it's possible.
Copy linkTweet thisAlerts:
@wdsueauthorFeb 05.2010 — the file im trying to use is : http://jayzadark.webs.com/radio/rahdu-rajesh.html

i just need a way do this in php :

$myvar=<script>document.write(StreamInformation.SONGTITLE())<script>;

echo$myvar;

even if the script is present in the php file.

now reconsidering it , i believe this thread belongs to php , right ?
×

Success!

Help @wdsue spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...