|
The way you've entered the code on the test page is as content, rather than source code - i.e the code has been copied into the visible part of the page. You need to be able to edit the page directly, rather than just using whatever editing tool it offers.
If you look at the source code for the test page, we can see that the editor has altered your code, commenting out the opening tag of the php block. Also, it's dumped it into a paragraph tag
<p>
<!--
If ($_POST["booking.php"]) { $iFrameURL = $_POST["booking.php"]; $i = 0;
foreach($_POST as $key => $value) { $i++; if($i == 1) { $iFrameURL .=
"?"; } else { $iFrameURL .= "&"; } $iFrameURL .= $key."=".$value;}
}<br>
?>
</p>
Since the page is displayed when the url is http://milleniumtravel.ca/result I'd guess that there's an index.php page inside that folder.
But it's really a bit hard to tell, since URL re-writing can map an address like that to something entirely different.
I'm sorry I can't provide better help. I'm certainly willing to, I just don't know how!
How did you create the test page? Was that from scratch/copy-paste, or was it via some kind of online editor? If it's an editor, then I've really got 3/5th and 5/8ths of no idea.
I've been up for about 17 hours now, so am far from my sharpest - though I guess I _could_ have a look around in the back-end if you really like.
Just send me another private email with some login details and I'll have a look for you - I must be in a good mood!
|
|
|
|
|
this is really bad coding practice anyways so maybe it's better it doesn't work?
"mostly watching the human race is like watching dogs watch tv ... they see the pictures move but the meaning escapes them"
|
|
|
|
|
i wanna site to create using php
|
|
|
|
|
Hi All,
Can Anybody help me in SMTP Setup for Bulk Emailing in PHP Programming.
Regards
www.ucsinfotech.com
|
|
|
|
|
Some suggestions[^].
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
You want to send thousands of email with php? in this case you will have to ensure you don't do it web command base. you will have to execute your php code from your server using shell command. better yet crontab
I wish I could believe there is an after life.
|
|
|
|
|
This is the code I'm having a problem with:
$sql = "SELECT SQL_CALC_FOUND_ROWS * FROM " . TBL_MEMBERS . " ORDER BY $order LIMIT $startRow, $numRows";
try {
$st = $conn->prepare( $sql );
$st->bindValue( ":startRow", $startRow, PDO::PARAM_INT );
$st->bindValue( ":numRows", $numRows, PDO::PARAM_INT );
echo "sql string = " . $sql . "<br />";
echo "just before we hit the execute<br />";
$st->execute();
echo "just hit the execute<br />";
$members = array();
foreach ( $st->fetchAll() as $row ) {
echo "pre";print_r($row);echo "/pre";
$members[] = new Member( $row );
echo "pre";print_r($members);echo "/pre";
}
ok had to remove the <> from the pre tags to makes it easier to read...
Ok, if I run the non-commented out version of the SQL it works fine and I get the result I expect, however if I run the commented out version I get the following error:
Query failed 1: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''5'' at line 1
I printed this out at the start of the function to check the values:
startRow = 0 and numRows = 5
I'm sure it's something stupid as I only spend about 5 - 10 hours a month doing PHP, so thank you in advance!
oh yeah:
mysql> select version();
+-------------------------+
| version() |
+-------------------------+
| 5.5.24-0ubuntu0.12.04.1 |
+-------------------------+
1 row in set (0.00 sec)
modified 20-Jul-12 13:55pm.
|
|
|
|
|
I figured it out... I checked the type of the variables and it thought the second was a string so I made some code changes and it's now a INT. Love those descriptive error messages, guess they have learned a few things from M$
|
|
|
|
|
hi there
how can i rebind and reuse a port that i make it busy in perior session?
in typical we close a busy port with socket_close() in php but when i click on X button on my browser for exit, the port left busy and i cant use it for next time.
by the way how can i close a socket when user click on X button for exit?
Thank you for your thoughts on this
|
|
|
|
|
i could not solve my problem
no body can help me?
|
|
|
|
|
I don't think you understand how client/server HTTP applications work. You cannot tell when a browser disappears, because HTTP is stateless and request/response based.
And if you're opening sockets in the server side code you're almost certainly doing something wrong. PHP is not the right tool for a stateful persistent TCP connection.
|
|
|
|
|
thanks for your reply BobJanova
i solve my problem with this code:
<?php
$fp = fsockopen("127.0.0.1", 26002, $errno, $errstr, 30);
fclose($fp);
?>
by this i could close my last open port, maybe is not a good solution
i found it here:http://php.net/manual/en/function.fsockopen.php[^]
PHP is not the right tool for a stateful persistent TCP connection.
so, what is good for do this?
and what are the chatroom that creates on php?
|
|
|
|
|
hi there
im new in php and want to create a chat server/client service for my project
so, do i have to start from socket programming in php for start?
what topics i must know?
should I use a specific framework like cake , zend , ... or it is soon to use theme?
by the way does php/mysql has offline help like msdn for asp or sth like SQL SERVER help?
please help me
thanks so much
modified 12-Jul-12 13:17pm.
|
|
|
|
|
excuse me but why nobody answer me?
i need your helps
plz answer me
tnx
|
|
|
|
|
|
Welcome to php world!
Here you will find many examples of what you are trying to achieve, but you got to look for the best rated one -
chat app[^]
It will be too early for you to use any framework.
Yes, you can download php manual here - php manual download[^]
Hope this helps!
|
|
|
|
|
You almost certainly want to use AJAX for this, and some form of data store for the 'chatrooms'. That way it will work in browsers and be resource-light. Alternatively, if you want a client/server non-HTTP chat, you don't want to be using PHP to write it.
|
|
|
|
|
thanks so much
BobJanova wrote: , if you want a client/server non-HTTP chat, you don't want to be using PHP to write it.
but my project title is "create a server/client chat service in php"
this is why that i want to create it in php
|
|
|
|
|
BobJanova wrote: if you want a client/server non-HTTP chat, you don't want to be using PHP to write it.
I hope you'll find the above added emphasis clears your doubt.
|
|
|
|
|
|
Hello guys;
I am from .NET background where I write data access code to any database platform using the DbFactory and the like.
I need a sample code that can connect to any database that all i need to supply is the database provider name, database name, user name, password, etc.
Thank you for your understanding and support.
|
|
|
|
|
PHP Manual
>> Function Reference
>> >> Database Extensions
>> >> >> Abstraction Layers
Peter
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
|
hi ,
if you want to connect to the Mysql database you can use the below code to connect and select your database
<?php
mysql_connect("localhost", "admin", "1admin") or die(mysql_error());
echo "Connected to MySQL<br />";
mysql_select_db("test") or die(mysql_error());
echo "Connected to Database";
?>
|
|
|
|
|
I truly appreciate your response.
|
|
|
|