Jump to content

Recommended Posts

Posted

I have a PHP script for my news page, which saves the value of a textarea to a text file, then another script on the shtml page displays the news using the php echo command. The script for saving the input works like a charm, but the echoing on the shtml page is a dud. I can't just switch the extension to .php because I have a javascript on the page that prompts the user for a password if they want to post news, which isn't supported on a php page. I tried editing the .htaccess file, and that didn't work, either. Sorry if this is hard to read, I posted this on about 0 sleep with a migraine.

Posted

The .shtml extension is for SSI (Server Side Includes). Sorta like cgi/perl. html and javascript should work fine on a page with a .php extension. Just write the html and javascript like you normally would on a page with a .html extension except use the .php extension.

 

Posted

That's what I've been trying to do, but when I change it to .php, the JS doesn't work. I got a new password system, that works with .php, so I'm fine now. Oh, and sorry for the double-post. The forum didn't let me post the first topic, but apparently it did :o

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...