39,316 Topics

Member Avatar for
Member Avatar for Chirag_97

Here is my Code ::: <?php if ($handle = opendir('images/')) { echo "Directory handle: $handle\n"; echo "Entries:\n"; while (false !== ($entry = readdir($handle))) { echo "$entry\n";?><br/> <?php } /* This is the WRONG way to loop over the directory. */ while ($entry = readdir($handle)) { echo "$entry\n"; } closedir($handle); } …

Member Avatar for AndrisP
0
204
Member Avatar for devianleong

Hi, now I've a function which is add product to cart: function addtocart($pid,$q,$attribute){ if($pid<1 or $q<1) return; if(is_array($_SESSION['cart'])){ $max=count($_SESSION['cart']); $_SESSION['cart'][$max]['productid']=$pid; $_SESSION['cart'][$max]['qty']=$q; $_SESSION['cart'][$max]['attribute']=$attribute; } else{ $_SESSION['cart']=array(); $_SESSION['cart'][0]['productid']=$pid; $_SESSION['cart'][0]['qty']=$q; $_SESSION['cart'][0]['attribute']=$attribute; } } And now my remove product function is : $id is generate from for loop in cart page which is same …

Member Avatar for LastMitch
0
173
Member Avatar for Melvinsdagate

dear friends. have been having problems on my new web page. i want to create chat,like,poke or wink, but i dont know how to go about this. please helpme out. (kazzysky2000@yahoo.com) my bbm pin is(2950df97).thanks

Member Avatar for LastMitch
0
218
Member Avatar for PerplexedB

In VB.net this works: client.Host = "smtp.gMAIL.com" client.Credentials = New System.Net.NetworkCredential("b040Mail2@gmail.com", "*****") client.Port = 587 client.EnableSsl = True I'm trying this in php (from Xampp) but it gives me an error: ini_set("SMTP","ssl://smtp.gmail.com"); ini_set("smtp_port","587"); ini_set("username","b040Mail2@gmail.com"); ini_set("password","*****"); $to = "p806Antwerp@gmail.com"; $subject = "testing"; $message = "This is the message"; mail($to,$subject,$message). Is there …

Member Avatar for PerplexedB
0
564
Member Avatar for t_thakar

Hi all I know how to sort an array but I dont know how to sort an array according to a value in the second array... <?php $array1 = array( array('name'=>'01','number' => 1), array('name'=>'07','number' => 7), array('name'=>'05','number' => 5), array('name'=>'06','number' => 6), array('name'=>'02','number' => 2), array('name'=>'03','number' => 3), array('name'=>'11','number' => …

Member Avatar for t_thakar
0
411
Member Avatar for renierdbruyn

Hi, Can some one tell me where I can find the function `get_user_by_identity_row_array() `in the flexi auth system? it is usauly called like : $this->data['user'] = $this->flexi_auth->get_user_by_identity_row_array(); I have looked every where, but maybe I’m missing it.. where can I find this? Thanks in advance.

Member Avatar for minitauros
0
202
Member Avatar for devianleong

Hi, is there any preg_match only allow `a-zA-Z0-9():[space]` ? Please help me =(

Member Avatar for diafol
0
129
Member Avatar for Kewne

Hi guys....ammm...I created a table in one function and then used it in another function. The temporary table is created this way: $tmpTable = "tmpTable"; myCreateTable($intHandle,$tmpTable,$schoolYr,$semester); CREATE TEMPORARY TABLE $tmpTable type = heap SELECT Payment.No FROM (Payment INNER JOIN Othr ON Payment.Autokey = Othr.key) I am passing the table name …

Member Avatar for diafol
0
196
Member Avatar for Priti_P

Hello there, My query is like- I have one pdf and xls file as link. When any employee try to click on that link, then it should ask me for credentials as name(pmp) and password(123) if these two things matches, thwn only it should allow you to view/download taht xls/pdf. …

Member Avatar for diafol
0
242
Member Avatar for vishaalMandge

want to restrict users to access particular webpages in my applicatipn. In my application I have 4 webpages like Mumbai, Delhi, Bangalore, Kolkata and I have havie 4 users say User1, User2, User3 and User4. All users are Admin. My requirement is that all 4 user can't access Mumbai page, …

Member Avatar for pzuurveen
0
188
Member Avatar for Britto_1

Hi all, I need to create a timetable in php. Example: we need to create timetable for two classes as LKG-A and LKG-B. There are 5 periods and 5 teachers for both the classes. Suppose if we choose a teacher for first period in LKG-A that teacher should not be …

Member Avatar for broj1
0
385
Member Avatar for NitsPatel

Hi I am new in magento. so, I don't know how to display products in home page .I add product in admin side .but, How to display it in frontside i don't know. So, Someone please help me Regards Nits

Member Avatar for best4earn
0
142
Member Avatar for websponge

Hi, I have been able to write to a text file, then another page can read from that file, all good.. Problem is I'm using multiple txt files just to set various variables. There is a reason I'm not using a database. Can I somehow, write to a file after …

Member Avatar for minitauros
0
199
Member Avatar for renierdbruyn

I have the following: in my **MODEL:** function get_advert() { $sql = "SELECT * FROM job_advert"; $advert = $this->db->query($sql)->result(); return $advert; } in my **CONTROLLER:** function get_detailed_list() { $job_advert = $this->ranking_model->get_advert(); echo '<pre>'; foreach ($job_advert as $j) { $job_id = $j->advert_id; $sql = "SELECT r.rank, a.advert_id AS job_id, a.job_title, d.firstname, …

Member Avatar for diafol
0
7K
Member Avatar for renierdbruyn

my goal is to list each job_title or job_id and under each job_title or job_id I want to list the candidates that qualify for that job I have this sql query: SELECT * FROM rank_results AS result WHERE result.job_id='{$job_id}' GROUP BY job_id ORDER BY rank ASC I know this is …

Member Avatar for diafol
0
204
Member Avatar for Anila_1

Hi. 'm new to php..please help.. 'm working with dropdown and submit button.. the dropdown contains certain values..if the user selectes one option in dropdown and clicks submit button, values corresponding to the dropdown should be displayed in table format from the database. the file name is campus.php 'm attaching …

Member Avatar for diafol
0
333
Member Avatar for saadi06

HI, I am trying to convert an audio file that is in wav format to mp3 format. I have installed apache and I am using windows 8. I downloaded the files for ffmpeg and tried to run the php script and convert the file but no success. What I am …

Member Avatar for veedeoo
0
3K
Member Avatar for faisaldss

I have written a script when clicked it creates a zip archive of files from the server and start downloading. Till this point everything is fine but what annoys is that it freezes the browser whether it be Chrome, Mozilla or IE. I assume this is due to overheard of …

Member Avatar for cereal
0
191
Member Avatar for GlenRogers

I have file that is supposed to pass the id of a link to using the ajax post method to a php file so that a div on my webpage updates. But nothing happens so i think the class is not being passesd. Can anyone see the problem. blog.js $('a.bloglink').click(function(e) …

Member Avatar for JorgeM
0
283
Member Avatar for boney

Hi, I need to show results with some filters on mysql query. The filters will be taken from $_GET['filter'] There are going to be multiple combinations of filters. Like : filter1+filter2, filter1+filter5, filter2+filter4 etc. I think i need to create a switch() for these filters. And based on the filters …

Member Avatar for diafol
0
179
Member Avatar for andreiviziru

so i have xampp installed on windows the address is localhost and i have a page test.php to preview my code a couple days ago everything worked fine when echoing <?php echo '<'.htmlentities('?php if ($_SESSION['Username']=='nume') { echo 'right name'; } else { echo 'wrong name'; } ?').'>'; ?> and when …

Member Avatar for andreiviziru
0
238
Member Avatar for ManzarOx

hello dani community. i am looking to get my fashion ecommerce website made in Magento and for that reason i wanna know what features magento is offering me by default and what features i need to ask my developers to built into my website (i have all my requirements documented). …

Member Avatar for minitauros
0
482
Member Avatar for rohan.verma.52012

i want to make comment box in my own site so i have to make database online but it shows some error, Please help me.!! this is the code <?php $comment = $_POST['comment']; $submit = $_POST['submit']; if($submit) { if($name&&$comment) { $con= mysql_connect("localhost", "root",""); if($con) { $query="create schema IF NOT EXISTS …

Member Avatar for minitauros
0
264
Member Avatar for titos97

On the form user enter rego no where it search database and display the output what i am looking is, if the entered data not match its should display " Record not found." <?php $search_Rego = ($_POST['RegoNo']); try { //open the database $db = new PDO('sqlite:iSearch.sqlite'); $result = $db->query("SELECT Fname …

Member Avatar for minitauros
0
370
Member Avatar for pssubash

I need all the possible combinations alphabets, numbers (a-z0-9) , _(underscore) and .(dot) which must satisfy the below conditions Please use between 6 and 30 characters. Please use only letters (a-z), numbers(0-9) The first character should be a letter (a-z) or number. The last character a letter (a-z) or number. …

Member Avatar for minitauros
0
135
Member Avatar for tkud

Hi,everyone.. I was wondering.. Is it possible to carry out other tasks in a php application while data is being uploaded(by that application) into a MySQL database?

Member Avatar for tkud
0
212
Member Avatar for ceeandcee

Posted earlier in the wrong forum...update here: Hey there...my code below had tradtionally only updated 1 of 4 fields. Now I want to update 2 of 8, but when I enter two variables it crashes. Any help would be appreciated. Code is here if( isset($_POST['Submit']) && $_POST['Submit']=='Submit' ) { foreach($_POST['CFHL_A'] …

Member Avatar for pritaeas
0
156
Member Avatar for andreiviziru

what i'm doing wrong? <?php if (isset($_SESSION['Username']=='axxxA')) { echo '<form action="upload.php" enctype="multipart/form-data" method="POST"> <input type="file" name="file" /><br /><br /> <input type="submit" value="Upload" /> </form>'; } else { echo 'Trebuie sa fii logat ca axxxA pentru a modifica profilul.'; } ?>

Member Avatar for andreiviziru
0
165
Member Avatar for garyjohnson

I have a code that places the time into a database in the format Year-Month-Date Time. The time isnt in Pm or Am. I want to change the code from that into Month/Day/Year and the time in am or pm. Is this possible? Or should I be using a different …

Member Avatar for diafol
0
370
Member Avatar for davy_yg

Hello, This I am trying to create an effective navigation code in CI. Let's say I have 10 shared pages that have the same navigation. Do I have to add the "## navigation link" codes over and over again (10 times ?) controllers/page.php <?php class Page extends CI_Controller { public …

Member Avatar for Dani
0
333

The End.