Jump to content

perezf

Members
  • Posts

    301
  • Joined

  • Last visited

    Never

Contact Methods

  • AIM
    way2fr3sh

Profile Information

  • Gender
    Male
  • Location
    Fort Lauderdale

perezf's Achievements

Advanced Member

Advanced Member (4/5)

0

Reputation

  1. Does anyone know how to fix the problem with php sorting numbers for some reason when i do a uasort and i have the numbers 1,6,9,10 it sorts it like this 1,10,6,9 How can i fix that?
  2. I need to do like a custom sort for instance, Say i have the numbers 1,2,3,4,5,6 And i want to sort them like this 4,2,3,6,1,5
  3. I have this query that i want to have all my items list in this specified order where i have list_zip How can i do this for some reason it is just showing everything just not in this order, SELECT * FROM snm_listings WHERE `list_country`='US' AND ( `list_zip`='33331' || `list_zip`='33330' || `list_zip`='33326' || `list_zip`='33332' || `list_zip`='33028' || `list_zip`='33325' || `list_zip`='33327' || `list_zip`!=NULL)
  4. I got it thanks for the help that really did work
  5. im not really sure on how to implement this
  6. How can i sort this array by the distance value
  7. Thanks everyone for the help, Do you guys also know how to do 301 redirects in Htaccess for instance im trying to redirect all my old pages to the new pages so if someone was to goto domainname.com/oldpage.html it would redirect them to domainname.com/newpage.html
  8. So what would be the htaccess code for the forcing of www.
  9. why does my session change if my domain has www or not? How can i keep the same session in php changing from www to no www and vice versa?
  10. I created a version of the hide and show, let me know if this helps <html> <head> <title>Display/Hide Content</title> <style type="text/css"> #ContentToDisplay { display: none; } </style> <script type="text/javascript" language="Javascript"> function showContent(idAlternate) { if(document.getElementById(idAlternate).style.display == 'block') { document.getElementById(idAlternate).style.display = 'none'; } else if(document.getElementById(idAlternate).style.display = 'none') { document.getElementById(idAlternate).style.display = 'block'; } } </script> </head> <body> <a href="#" onclick="javascript:showContent('ContentToDisplay');">Show/Hide Div</a> <div id="ContentToDisplay"> <p>This is the Hidden Content</p> </div> </body> </html>
  11. i need to see more of your code, for instance how are you handling the popup You need to make a javascript event based on that.
  12. I figured it out, I had to declare the array within the function I even added a go button so you can go to the url for each selection Heres the completed code <html> <head> <title>Chain Select Menu</title> <script type="text/javascript" language="Javascript"> function setNames(url,name) { this.setUrl = url; this.setName = name; } function setState() { var arraySetOne = Array(); arraySetOne[0] = new setNames('http://www.spacenetmedia.com','SpaceNet-Media'); arraySetOne[1] = new setNames('http://www.webomg.com','Online Media Group'); var arraySetTwo = Array(); arraySetTwo[0] = new setNames('http://www.google.com','Google'); arraySetTwo[1] = new setNames('http://www.yahoo.com','Yahoo'); var setValue = document.form1.fdrop.value; document.form1.fdrop2.options.length = 0; if(setValue == 1) { for(i=0;i<arraySetOne.length;i++) { var optionUrl = arraySetOne[i].setUrl; var optionName = arraySetOne[i].setName; arraySetOne[i] = document.createElement("OPTION"); arraySetOne[i].text = optionName; arraySetOne[i].value = optionUrl; document.form1.fdrop2.options.add(arraySetOne[i]); } } else if(setValue == 2) { for(i=0;i<arraySetTwo.length;i++) { var optionUrl = arraySetTwo[i].setUrl; var optionName = arraySetTwo[i].setName; arraySetTwo[i] = document.createElement("OPTION"); arraySetTwo[i].text = optionName; arraySetTwo[i].value = optionUrl; document.form1.fdrop2.options.add(arraySetTwo[i]); } } } function goToPage() { if(document.form1.fdrop2.value != '') { window.location.href = document.form1.fdrop2.value; } } </script> </head> <body> <form action="" method="POST" name="form1"> <select name="fdrop" onchange="javascript:setState();"> <option value="">Select Value</option> <option value="1">Hosting</option> <option value="2">Search Engine</option> </select> <select name="fdrop2"></select> <input type="button" name="gotopage" value="Go To Page" onclick="javascript:goToPage();" /> </form> </body> </html>
  13. Hey everyone im a beginner in javascript and i was wondering who could help me? Im having a problem with my javascript, that i made where i have 2 select boxes and one populates the other based on what you choose in the first one. The problem is after i choose the first one and then choose another and then go back to choose that same one the second select box will only show Undefined. <html> <head> <title>Chain Select Menu</title> <script type="text/javascript" language="Javascript"> function setNames(url,name) { this.setUrl = url; this.setName = name; } var arraySetOne = Array(2); arraySetOne[0] = new setNames('http://www.spacenetmedia.com','SpaceNet-Media'); arraySetOne[1] = new setNames('http://www.webomg.com','Online Media Group'); var arraySetTwo = Array(2); arraySetTwo[0] = new setNames('http://www.google.com','Google'); arraySetTwo[1] = new setNames('http://www.yahoo.com','Yahoo'); function setState() { this.setValue = ''; this.setValue = document.form1.fdrop.value; document.form1.fdrop2.options.length = 0; if(setValue == 1) { for(i=0;i<arraySetOne.length;i++) { this.optionUrl = arraySetOne[i].setUrl; this.optionName = arraySetOne[i].setName; arraySetOne[i] = document.createElement("OPTION"); arraySetOne[i].text = optionName; arraySetOne[i].value = optionUrl; document.form1.fdrop2.options.add(arraySetOne[i]); } } else if(setValue == 2) { for(i=0;i<arraySetTwo.length;i++) { this.optionUrl = arraySetTwo[i].setUrl; this.optionName = arraySetTwo[i].setName; arraySetTwo[i] = document.createElement("OPTION"); arraySetTwo[i].text = optionName; arraySetTwo[i].value = optionUrl; document.form1.fdrop2.options.add(arraySetTwo[i]); } } } </script> </head> <body> <form action="" method="POST" name="form1"> <select name="fdrop" onchange="javascript:setState();"> <option value="">Select Value</option> <option value="1">Hosting</option> <option value="2">Search Engine</option> </select> <select name="fdrop2"></select> </form> </body> </html>
  14. yes i did here is a sample of what i did while($row = mysql_fetch_array($result)) { $csv_output .= '"' . $row['products_id'] . '",' . '"' . $row['products_name'] . '",' . '"' . $row['products_model'] . '",' . '"' . 'R' . '",' . '"' . $row['products_price'] . '",' . '"' . 0 . '",' . '"' . '' . '",' . '"' . '' . '",' . '"' . 0 . '",' . '"' . 0 . '",' . '"' . 0 . '",' . '"' . $row['products_name'] . '",' . '"' . $row['products_description'] . '",' . '"' . $row['products_description'] . '",' . '"' . '' . '",' . '"' . 'default' . '",' . '"' . 'dsimg' . '",' . '"' . 3 . '",' . '"' . 0 . '",' . '"' . $row['products_image'] . '",' . '"' . $row['products_image'] . '",' . '"' . $row['products_image'] . '",' . '"' . 0 . '",' . '"' . 0 . '",' . '"' . 0 . '",' . '"' . 0 . '",' . '"' . 0 . '",' . '"' . 1 . '",' . '"' . 1 . '",' ; $csv_output .= "\n"; }
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.