Forum: PHP May 4th, 2009 |
| Replies: 7 Views: 429 the try this:
RewriteRule ^login$ login.php?req=preview&login_name=$1
or
RewriteRule ^([^.]+[^/])$ login.php?req=$1
If this is not your solution , then tel me clearly... |
Forum: PHP Mar 9th, 2009 |
| Replies: 5 Views: 284 i have tried this..
its worked fine for me...
Options +FollowSymlinks
RewriteEngine on
RewriteCond %{HTTP_HOST} ^mysite\.com [NC]
RewriteRule ^(.*)$ http://www.mysite.com/$1 [R=301,L] |
Forum: PHP Mar 6th, 2009 |
| Replies: 7 Views: 439 Don't use this statement $row=mysql_fetch_array($result); twice in your code...
Just remove first one , then you will find your expected result... |
Forum: PHP Mar 2nd, 2009 |
| Replies: 7 Views: 1,164 |
Forum: PHP Mar 2nd, 2009 |
| Replies: 7 Views: 1,164 I think the above is very simple method...
hmmmm...
another method is , you have use session arrays....
But above method.....No need to worry about anything else.... |
Forum: PHP Mar 2nd, 2009 |
| Replies: 7 Views: 1,164 you are right...
then why don't you use swith case in if loop...
then try like this...
if(!empty($_GET['err'])){
switch($_GET['err']){
case 'nosearch' : $msg="Your search returned no... |
Forum: PHP Mar 2nd, 2009 |
| Replies: 7 Views: 1,164 use thisecho $errormessages ['nosearch'];
instead of $_GET['nosearch'];
If my answer is not reached your question, be more clear... |
Forum: PHP Jan 31st, 2009 |
| Replies: 1 Views: 360 try like this:
"INSERT INTO `wall` (`user`, `from`, `content`, `date`) VALUES(.............etc. |
Forum: PHP Jan 31st, 2009 |
| Replies: 3 Views: 422 you forget to put comma after this line:
`title` VARCHAR( 255 ) NULL
that will fix your problem...
very silly, check out all possibilities for errors and finally you shoul post your question... |
Forum: PHP Nov 18th, 2008 |
| Replies: 5 Views: 539 yes..
and also look at query optimization and indexing,if you are using joins and complex query in your page...
Minimize your loop as make as possible..this is better on rather to set a time for... |
Forum: PHP Nov 8th, 2008 |
| Replies: 1 Views: 547 check this:
echo $qur="INSERT INTO person(pID, firstName, middleName, lastName) VALUES('$pid', '$firstName', '$middleName', '$lastName')"
mysql_query($qur);
copy and paste what it gives out... |
Forum: PHP Nov 4th, 2008 |
| Replies: 9 Views: 1,707 check this for reference:
https://developer.mozilla.org/En/DOM:window.open |
Forum: PHP Nov 4th, 2008 |
| Replies: 9 Views: 1,707 try this or post your code...
window.open("","newWin","toolbar=no,location=no,resizable=no,
width=200,height=200,left=100,top=100") |
Forum: PHP Oct 25th, 2008 |
| Replies: 7 Views: 1,650 not the matter , the above query is possible or not...if our session time and date matches the database fields , it will give according result...
But we want the desired output from that... |
Forum: PHP Oct 24th, 2008 |
| Replies: 7 Views: 1,650 hello jackakos,
in this line
$get_event = "select * from event where event_time like $_SESSION['event_time'] and emp_no like $_SESSION['check_array']";
it is better to use = while getting data... |
Forum: PHP Oct 23rd, 2008 |
| Replies: 10 Views: 1,814 i checked your code...
why are you using checkbox code in echo statement...thats why the problem raises...
use it as html code..
here is update code...that database belongs to my table..please... |
Forum: PHP Oct 23rd, 2008 |
| Replies: 10 Views: 1,814 Hello jackakos,
post your whole code of that page...i will check it now... |
Forum: PHP Oct 22nd, 2008 |
| Replies: 8 Views: 1,213 then post your required code...... |
Forum: PHP Oct 22nd, 2008 |
| Replies: 8 Views: 1,213 I think we don't need to pass a variable to an included file, it already has
access to all variables in the including script. It becomes part of the
script that is including it.
$page =... |
Forum: PHP Oct 21st, 2008 |
| Replies: 10 Views: 1,814 try this:
foreach($_POST["dname"] as $key=>$val){
echo "key: ". $key. " value: ". $val ."<br />\n"; |
Forum: PHP Oct 18th, 2008 |
| Replies: 4 Views: 1,019 yes, in POST variable are stored in a array called $_POST...so we can retrieve them with key like $_POST['lang']; or $_POST['name']; or some thing...No matter of order...
or As adilkhan said,try to... |
Forum: PHP Oct 17th, 2008 |
| Replies: 6 Views: 681 your post is not clear for me...
please post again with clear...i am not telling totally wrong.. |
Forum: PHP Oct 17th, 2008 |
| Replies: 7 Views: 677 so,you wan to delete only that post,then simple use:
$query = "DELETE FROM `forumtutorial_posts` WHERE postid = '$parentid'";
i don't know, why you are writing the below line..could you please... |
Forum: PHP Oct 17th, 2008 |
| Replies: 10 Views: 1,814 this is the code:
<script type="text/javascript">
function chkChecks(){
isChecked=false
for(var i=0;i<document.forms["new_page"]["allowed[]"].length;i++){... |
Forum: PHP Oct 17th, 2008 |
| Replies: 7 Views: 677 pass the auto increment id to the delete command..which is unique in your table...
or post table structure ...
and here what are those parentid and postid...
i think postid is your unique id...??? |
Forum: PHP Oct 15th, 2008 |
| Replies: 5 Views: 517 see this:
$variable="a";
$sql = "select * from characters where letters like '%".$variable."%'"; |
Forum: PHP Oct 15th, 2008 |
| Replies: 5 Views: 517 hello try this:
$sql = "select * from characters where letters like '%a%'";
$query = mysql_query($sql);
$count=mysql_num_rows($query);
echo $count; |
Forum: PHP Oct 14th, 2008 |
| Replies: 5 Views: 765 i think no difference between them.... |
Forum: PHP Oct 13th, 2008 |
| Replies: 5 Views: 765 session_register() registers the global variable with that name in the current session.
yes...only the checked ones are added to that array..
you have to read more about sessions here... |
Forum: PHP Oct 13th, 2008 |
| Replies: 5 Views: 765 see this code...it will print only clicked checkboxes..
foreach($_POST['checkbox'] as $key=>$val){
echo "key: ". $key. " value: ". $val ."<br />\n";
echo $_POST['checkbox'][0];
and this... |
Forum: PHP Oct 13th, 2008 |
| Replies: 3 Views: 2,731 check this:
http://developer.yahoo.com/php/howto-reqRestPhp.html |
Forum: PHP Oct 8th, 2008 |
| Replies: 6 Views: 609 hello..
that is CAPTCHA ..means creating dynamic number on an image...
It is used to prevent spam abuse on the websites
For more information:... |
Forum: PHP Oct 8th, 2008 |
| Replies: 9 Views: 763 did your problem got solved???
Indian.....AndraPradesh.. |
Forum: PHP Oct 8th, 2008 |
| Replies: 9 Views: 763 This function will turn output buffering on. While output buffering is active no output is sent from the script (other than headers), instead the output is stored in an internal buffer.
means...... |
Forum: PHP Oct 8th, 2008 |
| Replies: 9 Views: 763 use session_start only once..
means use at your page which is having the above code which you have posted above..
remove session_start(); line from your function.php page..
and also use... |
Forum: PHP Oct 8th, 2008 |
| Replies: 9 Views: 763 and also try these lines and tel me what you got there:
echo $r="SELECT * FROM `accounts` WHERE `name` = '" . $username . "'";
$result = mysql_query($r); |
Forum: PHP Sep 26th, 2008 |
| Replies: 6 Views: 1,213 use this:
if(empty($_GET))
{
//code
} |
Forum: PHP Sep 25th, 2008 |
| Replies: 4 Views: 996 hello...
Actually the $currentFile gives you the whole path of your file ,something like web/mysite/index.php
These two lines #
$parts = Explode('/', $currentFile);
#... |
Forum: PHP Sep 24th, 2008 |
| Replies: 4 Views: 996 hello servis...
the following function will get your page name:
$currentFile = $_SERVER["PHP_SELF"];
$parts = Explode('/', $currentFile);
$pagename=$parts[count($parts) - 1];
echo $pagename;
... |
Forum: PHP Sep 23rd, 2008 |
| Replies: 2 Views: 1,588 |