Ambiera ForumDiscussions, Help and Support. |
|
|
|||||
|
So, I have published the page to local disk and then I checked the preview, but no code is visible in the php box. Also, if I look at the code view for the page, it says 'PHP code will be inserted here when published as PHP page'. Well, it is published and it is a php page, so I don't understand this. Help please! The form code: <form action="index.php" enctype="application/x-www-form-urlencoded" method="POST" id="form_19edd504"><div id="form_19edd504_padding" ><div class="textstyle2"> <span class="textstyle7">Email address: </span> </div> <div class="textstyle5"><input type="text" value="" title="" name="Email address" maxlength="35" id="edit_2c509ff5" > </div> <div class="textstyle2"> <span class="textstyle7"><br/>Contact name: </span> </div> <div class="textstyle5"><input type="text" value="" title="" name="Contact name" id="edit_7ecb5c5f" > </div> <div class="textstyle2"> <span class="textstyle7"><br/>Your message: </span> </div> <div class="textstyle5"><textarea name="Your message" title="" cols="36" rows="4" id="edit_24ad08ac"></textarea> </div> <div class="textstyle2"> <span class="textstyle7"><br/></span> </div> <div class="textstyle1"><input name="Button1" type="submit" value="SEND" title="" id="button_6983ed74" > </div> <div style="clear:both"></div></div></form><span class="textstyle7"><br/></span><div id="php_4072b823"><!-- PHP code will be inserted here when published as PHP page --> </div> |
||||
|
When hitting "Preview", this will be created because in preview mode, the file is just opened in the browser from disk, as html file. If the PHP code would be in there, it would display the code as plain text in the browser, causing your website to look strange. The code will be inserted with the "publish to local disk" or "publish to the internet" option. Just not in preview mode. |
||||
|
Sorry, I don't understand... It was/is published to local disk but no php code is showing when I look at the code view, I realize it would look strange in browser view. |
||||
|
You are likely looking at a chached or the wrong file. This only happens in preview mode. But if you are not sure, send me the .rcd file and I'll take a look for you. (See support -> contact) |
||||
|
Hi. What only happens in preview mode? I already had index.html under or in the .rcd file and I simply renamed this to index.php as opposed to adding a new file and renaming it to index.php because this seemed illogical to me. I then followed the form tutorial exactly; I completed the form then added the php script as per tutorial (Action: index.php). But no php code is showing if I look at the code view of index.php file. I'll send you the .rcd file via support -> contact. Thank you. OK, I tried contacting you (via support -> contact), but this didn't work. It said I was trying to send spam. |
||||
|
you have renamed inner RC, in the properties of this site by file name? |
||||
|
Many thanks. Yes, I renamed the file under properties as index.php right at the start. Anyway, I've looked at the code view again, and this time the php code is showing, so I must have been looking at the cached file previously, although that is a bit odd as I had looked at the code view at least two or three times initially and the php code wasn't showing; but it's showing now so that's the main thing :) My guess is that the browser cache hadn't cleared properly or something similar... |
|