Posts
 
Reputation
Joined
Last Seen
Ranked #248
Strength to Increase Rep
+10
Strength to Decrease Rep
-2
94% Quality Score
Upvotes Received
127
Posts with Upvotes
123
Upvoting Members
68
Downvotes Received
8
Posts with Downvotes
8
Downvoting Members
7
50 Commented Posts
~261.38K People Reached
Favorite Tags
Member Avatar for danny4444

I was also facing so many issues for mail attachment. Finally i end up with this. I have made this function, hope this helps you. [CODE] <?php //======================================= // mail sending start //======================================= $to = 'vibha@domainname.com'; $fromName = 'Administrator'; $fromEmail = 'admin@domainname.com'; $subject = 'Subjest is here'; $message = 'Message …

Member Avatar for Rick_15
0
3K
Member Avatar for mehrantahir
Member Avatar for noelpasia

[QUOTE=noelpasia;1577222]if(isset($_GET['advance_searching']) && !empty($_GET)){ $where = ""; if($_POST['search_remarks']!="") { $s[] = "`process` = '" . mysql_real_escape_string($_POST['search_remarks']) . "'"; } if($_POST['search_industry']!="") { $s[] = "`process` = '" . mysql_real_escape_string($_POST['search_industry']) . "'"; } if($_POST['search_position']!="") { $s[] = "`process` = '" . mysql_real_escape_string($_POST['search_position']) . "'"; } if($_POST['search_location']!="") { $s[] = "`process` = '" . …

Member Avatar for FOURATI
0
3K
Member Avatar for coleguitajuan

Try this. [CODE] <script type="text/javascript"> window.onload=function() { if (document.getElementById("country")) { document.getElementById("country").onchange=function() { switchme(this); } } } function switchme(SNewSel) { var ind = SNewSel.selectedIndex; var txt = document.getElementById('country_code'); switch (ind) { case 1: txt.value = "+93"; break; case 2: txt.value = "+358"; break; case 3: txt.value = "+355"; break; default: txt.value=''; …

Member Avatar for coleguitajuan
0
1K
Member Avatar for meazza

You can not get labels after form submission. You can create hidden type field and value can be same as label, then when form submitted you can get hidden field value for labeling.

Member Avatar for Rashid_4
0
9K
Member Avatar for oliprik

Try 'U' in small case. [CODE] echo $sql = "SELECT [B]u[/B]sername FROM login_tbl WHERE username='".$username."' and password='".$password."'"; $result = mysql_query($sql, $connectID); [/CODE] If it still not works then run echoed query in phpmyadmin.

Member Avatar for diafol
0
3K
Member Avatar for 080346

In php you can do this by ffmpeg. You need to install it in server. Check this : [URL="http://lmgtfy.com/?q=ffmpeg+php+tutorial"]http://lmgtfy.com/?q=ffmpeg+php+tutorial[/URL]

Member Avatar for edisath
0
225
Member Avatar for shahiduop

Here i have written complete code. Try it, its easy to understand. [CODE] <? mysql_connect('localhost','root',''); mysql_select_db('test'); if(isset($_REQUEST['delete'])) { $deleteCb = $_REQUEST['deleteCb']; for($i=0;$i<count($deleteCb);$i++) { $news_id = $deleteCb[$i]; $q = "delete from newslist where news_id= ".$news_id; mysql_query($q); } header("location:test.php"); exit; } ?> <form name="form" id="form" method="post"> <table width="400" border="1" cellspacing="0" cellpadding="0"> <? …

Member Avatar for pushpatiwari
0
2K
Member Avatar for Viruthagiri

Here is code for index.php. check it, hope it is what you want. [CODE] <?php //File Snatcher 2.7 define('_ALLOWINCLUDE',0); include 'setting.php'; $version = '2.7'; ////////////////////////////////////////////// //Do Not Change Below Here//////////////////// ////////////////////////////////////////////// if (function_exists('curl_init')) { $snatch_system = 'curl'; } ?> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <link rel="stylesheet" …

Member Avatar for Saad Awan
0
571
Member Avatar for jacksantho

Below is not a complete code,it is just a logic. Try to implement at your end. [CODE]<select name="dropd" id="dropd"> <option value=""> - - Select - -</option> <? if(manager is logged in) { $res = select manager list from database while($rs = mysql_fetch_assoc($res)) { ?> <option value="<?=$rs['manager-id']?>"><?=$rs['manager-name']?></option> <? } } if(employee …

Member Avatar for tapananand
0
787
Member Avatar for camillee

You can use js code in echo statement, Logic: [CODE] <? if(! valid username or password) { echo '<script language="javascript">alert("Please enter valid username and password");</script>'; header("Location:currentpage.php"); exit; } else { //--- continue..... } ?> [/CODE]

Member Avatar for diafol
0
5K
Member Avatar for tejasluvs

[CODE] <?php define("MAJOR", 'pounds'); define("MINOR", 'p'); class toWords { var $pounds; var $pence; var $major; var $minor; var $words = ''; var $number; var $magind; var $units = array('','one','two','three','four','five','six','seven','eight','nine'); var $teens = array('ten','eleven','twelve','thirteen','fourteen','fifteen','sixteen','seventeen','eighteen','nineteen'); var $tens = array('','ten','twenty','thirty','forty','fifty','sixty','seventy','eighty','ninety'); var $mag = array('','thousand','million','billion','trillion'); function toWords($amount, $major=MAJOR, $minor=MINOR) { $this->major = $major; $this->minor …

Member Avatar for nitinr
0
868
Member Avatar for rajalakshmi2810
Member Avatar for aMOEBa

This can be done using java script. [CODE] <a href="whatever.htm" onClick="window.print();return false"><img src="print.gif"></a> [/CODE]

Member Avatar for geoamins2
0
219
Member Avatar for vibhaJ

I have mobile web services written in PHP. Ant it is running on Apache Linux. Suddenly since yesterday our server became too slow. We found the reason that there are many continuous connection is coming to our server. Which is engaging bandwidth and making server slow. We have asked hosting …

Member Avatar for vibhaJ
0
194
Member Avatar for jrotunda85

I use below logic. In login form place a new hidden field which will have user's current location with query parameter. [CODE] <input type='hidden' name='page' value='<?=basename($_SERVER["PHP_SELF"]).'?'.$_SERVER["QUERY_STRING"]?>' /> [/CODE] In php side coding use below redirection. [CODE] header('location:'$_POST['page']); [/CODE]

Member Avatar for bakhtn
0
2K
Member Avatar for vibhaJ

I was struggling long for proper image resize function for maintaining image ratio. Finally i end end up with merging and changing all codes and it works ! function resizeImage($sourceFile,$destFile,$width,$height) sourceFile => Full path along with filename destinationFile => Full path along with filename I hope this will help coders..

Member Avatar for diafol
1
334
Member Avatar for pjh1985

echo your login select query and try to debug it. md5 is just for encryption there might be some issue in coding.

Member Avatar for aareyes00
0
5K
Member Avatar for vizz

As pritaeas says, have you tried simple htaccess rule?? like below? # This allows you to redirect your entire website to any other domain Redirect 301 / http://www.google.com/ First of all check if htaccess is working in your server or not?

Member Avatar for vizz
0
432
Member Avatar for just.irwan

You need to work on mysql queries. No one can help you without your database structure.

Member Avatar for diafol
-3
118
Member Avatar for BadManSam

From Google... <?php // ------------------------------------------------------------ function recursive_remove_directory($directory, $empty=FALSE) { if(substr($directory,-1) == '/') { $directory = substr($directory,0,-1); } if(!file_exists($directory) || !is_dir($directory)) { return FALSE; }elseif(is_readable($directory)) { $handle = opendir($directory); while (FALSE !== ($item = readdir($handle))) { if($item != '.' && $item != '..') { $path = $directory.'/'.$item; if(is_dir($path)) { recursive_remove_directory($path); }else{ …

Member Avatar for vibhaJ
0
122
Member Avatar for vijayram

From getParameter function it seems meetnewpeopleId should be passed to url. i.e. yourpage.php?meetnewpeopleId=177 Are you passing meetnewpeopleId in url or any object?

Member Avatar for vibhaJ
0
185
Member Avatar for laura301019

<? if(form is submitted) { $transportAll = $_POST['transport']; foreach($transportAll as $transport) { echo '<br />You have selected:'.$transport; } echo '<br />Total:'.count($transportAll); } ?>

Member Avatar for vibhaJ
0
117
Member Avatar for tim-work

1) First of all make sure all your href should have seo url, which you finally want i.e. fullnews.php/123/This-is-the-Headline So below code will make such href. function seo($input){ $input = mb_convert_case($input, MB_CASE_LOWER, "UTF-8"); //convert UTF-8 string to lowercase $a = array('č','ć','ž','đ','š'); $b = array('c','c','z','dj','s'); //$input = strtr($input, "čćžđšè", "cczdse"); not …

Member Avatar for vibhaJ
0
186
Member Avatar for hwoarang69
Member Avatar for Joshuamandrew
0
186
Member Avatar for dani0

> ORDER BY RAND() ORDER BY RAND() will do the same thing. Better to use it instead of 4 line coding. For better practice when things are possible from mysql query better to use it directly instead of 2-3 php operation.

Member Avatar for vibhaJ
0
173
Member Avatar for Venom Rush
Member Avatar for blaaam

Below is two functions which can be used for insert and update tables. When you have large table you can try it, you need to pass array to function as shown in example. I know it is off to your question but this code may help you. <? //======= function …

Member Avatar for blaaam
0
356
Member Avatar for dagtad
Member Avatar for ehpratah

As blocblue says you can set timezone. If you have access of php.ini, you can also set timezone in directly php.ini.

Member Avatar for ehpratah
0
2K