Posts
 
Reputation
Joined
Last Seen
Ranked #423
Strength to Increase Rep
+8
Strength to Decrease Rep
-2
94% Quality Score
Upvotes Received
48
Posts with Upvotes
41
Upvoting Members
36
Downvotes Received
4
Posts with Downvotes
4
Downvoting Members
3
11 Commented Posts
~117.25K People Reached
Favorite Tags
Member Avatar for dean.ong.14
Member Avatar for Dani

Just came across my first daniweb google hit. Searched on "Coldfusion wamp" past year. 8th link on page.

Member Avatar for j.khurram
11
5K
Member Avatar for paulkd

...was asked for some php file upload code, so I thought I would post some stripped down, barebones code that I use in admin/dashboard pages to add/change images associated with products. Please see attached image for folder setup. The code uses the [jQuery Form](http://malsup.com/jquery/form/) plugin by Mike Alsup. **index.php** has …

Member Avatar for NaReSh_12
1
11K
Member Avatar for James_43

Hi James, I think your second listing should actually be coded:- $listing = [ 'one' => $x, 'two' => $y, 'three' => $z ];

Member Avatar for James_43
0
195
Member Avatar for James_43

Hi, Try not to use for loops to iterate an array. I'm not sure what you are trying to achieve, but i've constructed similar data and looped through it. Hope it helps. $array = array( '798D25C0DEABD' => array('quantity' => 1, 'price' => 20.5), '40B2B0FA3D222' => array('quantity' => 1, 'price' => …

Member Avatar for James_43
0
325
Member Avatar for James_43

Hi James, $response[] = will create (if it doesn't exist) or append the right-hand value to the $response array. So if $html->data->identifier is a simple string, e.g. 'Price', then a new array would be ['Price'] or array(0=>'Price') $order->get_items() appears to be a nested object not an array. I've created a …

Member Avatar for paulkd
0
250
Member Avatar for Firmace

<style>.selected {background: yellow}</style> <?php $menu[] = array('menu_id' => 1, 'menu_text' => 'Home'); $menu[] = array('menu_id' => 2, 'menu_text' => 'Service'); $menu[] = array('menu_id' => 3, 'menu_text' => 'About Us'); $menu[] = array('menu_id' => 4, 'menu_text' => 'Contact Us'); $selected = (isset($_GET['side']) and !preg_match('/\D/',$_GET['side'])) ? $_GET['side'] : 0; $i = 0; …

Member Avatar for diafol
0
1K
Member Avatar for giao.can

If your checkboxes are there to purely signify that there will be content in a corresponding text field, then I would lose the checkboxes and simply check for form field content in your form handler. You have too any forms. "There can only be one" (Highlander) :D

Member Avatar for Mashetty
0
5K
Member Avatar for phfilly
Member Avatar for gcardonav
Member Avatar for dhani09
Member Avatar for DaveyMoyes

Hi, Syntax error :-) `setTimeout(function(){alert("my message");location.replace("/new-page.php");},1000);`

Member Avatar for anitha407
0
6K
Member Avatar for david.roun.7_1

<img src="" id="pics"> <script> var m=new Date(); var imageArray = [ "Holiday/HolidayDesktops/Newyear.jpg", "Holiday/HolidayDesktops/Vday.jpg", "Holiday/HolidayDesktops/St.Patday.jpg", "Holiday/HolidayDesktops/Easter.jpg", "Holiday/HolidayDesktops/MemorialDay.jpg", "Holiday/HolidayDesktops/NatFlagDay.jpg", "Holiday/HolidayDesktops/July4.jpg", "Holiday/HolidayDesktops/WomensEqualityDay.jpg", "Holiday/HolidayDesktops/LaborDay.jpg", "Holiday/HolidayDesktops/Halloween.jpg", "Holiday/HolidayDesktops/Thanksgiving.jpg", "Holiday/HolidayDesktops/Christmas.jpg", ]; document.getElementById("pics").src=imageArray[m.getMonth()]; </script>

Member Avatar for david.roun.7_1
0
233
Member Avatar for yankeefan24

It's actually an HTML form. :-) You will need to use JavaScript and Ajax (jQuery make things easier). Your JavaScript will be called by your main file (the one with the form) and will simply run Ajax code to post all your form variables to a form handler. The form …

Member Avatar for danarashad
0
294
Member Avatar for kanoy83
Member Avatar for <M/>
Member Avatar for ashutosh08
0
206
Member Avatar for Mok858
Member Avatar for NextCom
Member Avatar for dheerajvermawd

Hi, I would hope that you have some PHP knowledge. If so, here is some very basic code to save your uploaded file to the server. You will need to substitute your own $dest value. post-cv-action.php <?php $filename = $_FILES['attachment']['name']; $source = $_FILES['attachment']['tmp_name']; $dest = $_SERVER['DOCUMENT_ROOT'].'/test/'; move_uploaded_file($source,$dest.$filename); ?>

Member Avatar for paulkd
0
276
Member Avatar for Sanjay_6
Member Avatar for laura301019

Instead of this route, you could allow the user to enter two recipients separated by either a comma or semi-colon - similar to how many email clients work.

Member Avatar for EvolutionFallen
0
112
Member Avatar for ehpratah

What is it's purpose in refreshing every 10 seconds? Do you record the amount of times it's reloaded?

Member Avatar for ehpratah
0
357
Member Avatar for Edwin_2
Member Avatar for davy_yg

IF you are emailing the contents of a form. In your form handler:- $this->load->library('email'); $this->email->from('your@example.com', 'Your Name'); $this->email->to('someone@example.com'); $this->email->cc('another@another-example.com'); $this->email->bcc('them@their-example.com'); $this->email->subject($yourFormSubject); $this->email->message($concatOfFormFieldsYouWantToSend); $this->email->send();

Member Avatar for davy_yg
0
324
Member Avatar for Waado

What are you trying to achieve? I can understand reloading a page every x seconds, but why would you display a page and then x seconds later reload the page just once?

Member Avatar for JorgeM
0
1K
Member Avatar for klemme

overwrite line 16 (above) with this:- $id = 1000; $key = array_search($id, $cart['data']['product_id']); if($key!==FALSE) { unset($cart['data']['product_id'][$key]); unset($cart['data']['quantity'][$key]); } print_r($cart); die;

Member Avatar for paulkd
0
3K
Member Avatar for sruthisru

Using your original code and looking at header in the php.net documentation I've constructed this:- if(file_exists($filename)) { header('Content-Type: application/octet-stream'); header('Content-Disposition: attachment; filename="'.$filename.'"'); readfile($filename); } else { die('not ok'); }

Member Avatar for paulkd
0
242
Member Avatar for BadManSam

You just need to read a little more. Here's one [article](http://www.phphaven.com/article.php?id=65) from a google search. I've picked mysqli rather than mysql as mysql is so last year :-)

Member Avatar for Derice
-1
411
Member Avatar for kelley82879
Member Avatar for msz900

Are you saying that none of your pages are displaying $_SESSION['username'] ?

Member Avatar for jkon
0
289