Open file without <a href

S

salonowiec

Can I modify .html page so that it opens a file immediately "onload",
without link like <a href... etc? (similar to page where the only code is
img src...).
 
J

Jukka K. Korpela

Scripsit salonowiec:
Can I modify .html page so that it opens a file immediately "onload",
without link like <a href... etc? (similar to page where the only
code is img src...).

In a sense you could, using <object>, <iframe>, <embed>, or <frame>. All of
these are unreliable and would at least require a link as a fallback to be
minimally reliable.

But why would you do that? I'm fairly sure that the original problem is much
easier to solve than the problems you would create by using any of such
"solutions".
 
S

salonowiec

And you are right! My problem is to rename the file to .php and to put some
small php code at the beginning so as the page would be available for a
group of users only. Thanks for attention and asking for further tip...
 
A

Art

salonowiec,
PHP is a pre-processor service that is executed on the web server that
supports your site, not in the browsers. So all of your visitors would
be covered if PHP is enabled on your web server, regardless of the
browser or host.

I use "php includes" for my common masthead/navigation bar, footers,
etc. After the server has processed the php file, these statements are
removed and replaced by the contents of the included files and delivered
to the browser for rendering. You can see this by doing a "view source"
in your browser after the page has loaded.

I normally include comment wrappers in the included files or around the
"include" statements for ease of debugging.

Art

And you are right! My problem is to rename the file to .php and to put some
small php code at the beginning so as the page would be available for a
group of users only. Thanks for attention and asking for further tip...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top