Jump to content

optikalefx

Members
  • Posts

    363
  • Joined

  • Last visited

    Never

Everything posted by optikalefx

  1. is there anyway without moving the folder? Im using an integrated solution, and its a pain to move the folder which means ill have to find everywhere in the code that references that folder. :/
  2. i have a folder /downloads what permissions do i need on that folder that will make it so you can't navigate to it, or any files in it. but using php you can read, and use move_uploaded_files
  3. Ok so this problem ONLY happens on the iPad. It won't show ANY image links on my site. For every sing one it says XML self-closing tag syntax used on <a> The tag will not be closed. And because of this the site looks HORRIBLE. It looks fine on iPhone, mac, windows, every browser. Just iPad it F&*ks up on. Here is the Doctype and stuff, and it DOES validate with w3c. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html dir="ltr" lang="en" xmlns="http://www.w3.org/1999/xhtml"> <head> So this is a vbulletin site. So i let the site load, copied the source, and made a webpage with just that, and that worked fine. So the browsers are fixing some error when they render that I can't find. Is there any kind of tool, or a way to catch the HMTL content without a browser changing the HTML first? Thanks!!
  4. can't help you if your code doesnt run. we need absolute URLS to ur js and css files
  5. this one is tricky. I am doing a lot DOM manipulation with js and jquery. After some time i get a lot of these Great blog <span style="font-weight: bold;"> post <span style="font-weight: bold;"> from the Ba </span> ltimo </span> team Think anyone can come up with a function that starts at the body, and traverses the entire DOM and cleans this kind of stuff up? Its ok if it takes a while. the above code should be cleaned to this <span style="font-weight:bold">Great Blog Post from the Baltimore team</span> of course you have to worry about not combing elements if they don't have the same style, and you can't just compare siblings, because sometimes children need to combined up to their parents. so 2 sub functions to make this happen would be like combineParentWithChild and then CombineSiblings i think. thanks!
  6. i didn't mean session id, i meant id of that user matching the id thats in the transaction db table.
  7. myWin = window.open(''); myWin.close();
  8. im making a script for downloading files that have been purchased. On the download page... call a php file passing the transaction id download.php?file=2234234982374982734892739842 in download.php go though the db, select that transaction check that the session[userid] matches the id of the userid who made that transaction if it does, serve the zip file to the user Using this method, it requires the user to be logged in to be able to click his download link. So he can't just pass the link around. Also, he can log in and re download the file as many times as he wants, because he is logged in. Anyone find any holes in this method?
  9. get a paypal payments pro account, and they have an sdk that allows you to process cards on your site without ever leaving your site. They don't even know paypal was used
  10. your just not echoing out. <?php if ($site = "www.agcooponline.com") { ?> <link href="../templates/tsgcalpha/css/harvestauction.css" rel="stylesheet" type="text/css" media="all" /> <?php } ?> should be <?php if ($site = "www.agcooponline.com") { ?> echo "<link href='../templates/tsgcalpha/css/harvestauction.css' rel='stylesheet' type='text/css' media='all'>" /> <?php } ?> But please don't do this, re write it, your code is very very messy.
  11. grab a DOM reference to the <img> element and change its .src or .setAttribute("src","whatever.jpg");
  12. ok try running a basic shell command like shell_exec('pwd'); and see if you get output. If you do, then it will mostly likely be a PHP permission problem.
  13. run the commands in terminal first. if they work in terminal then they will work with shell_exec()
  14. Sounds like SQL REPLACE statement. It will insert an entry or update the existing in a mysql db. You can also use UPDATE if you want to make a separate SQL call.
  15. what is the purpose here? PHP code is invisible to the end user.... Generally you just replace variable names with single letters and get rid of ALL white space in the code.
  16. do you want lastInsertID? <?php $link = mysql_connect('localhost', 'mysql_user', 'mysql_password'); if (!$link) { die('Could not connect: ' . mysql_error()); } mysql_select_db('mydb'); mysql_query("INSERT INTO mytable (product) values ('kossu')"); printf("Last inserted record has id %d\n", mysql_insert_id()); ?> or if you need it more advanced, check out mysql triggers here is a video i made
  17. you mean subdomains? like site1.mysite.com? I've never seen site1/mysite.com If that is the case, you need to look into htaccess 301 redirects for certain users to redirect to certain sub domains. However as the server admin you need to make those subdomains point to the right places in apache.
  18. Call goDaddy... This happens all the time with them
  19. Any one can offer some help on this? I even tried curl and it still has the same problem. The upload is successful but the ftp_put returns false. when i use curl the upload is successful but curl_errno($ch); returns an error. I have all the my php.ini settings up high, i can't figure out what to do. Is there another way to get large files onto an FTP server on the web?
  20. There is no problem with the form processing. I have that value increased in the php.ini file. It has something to do with the size of the file in ftp_put Try using ftp_put with a 90m file and see what it returns.
  21. I found this constant ftp_set_option($conn_id, FTP_TIMEOUT_SEC, 600); but even setting that hight seems to freeze the script at the end instead of failing the put.
  22. Anyone had any success using FTP to upload a file say 90m? im using ftp_put and it returns false. BUT the file DOES upload just fine. I even downloaded and tested it, its the full file. But ftp_put still returns false. Now with a 20m file it returns true. I have all my php.ini vars for time and size set up really really high, and same problem. I still feel like its a timeout problem but it shouldn't be anymore... i have these set default_socket_timeout = 1000 upload_max_filesize = 1024M post_max_size = 1024M max_execution_time = 1000 max_input_time = 1000 memory_limit = 1024M The file is 91m and takes about 6 minutes. I'm using ajax to do the ftp, and im using another ajax function to check the size against the ftp size, after it reaches 100% it takes about 1 minute to return false from the ajax call. Thats why it feels like it's timing out. I don't know. Thanks
  23. Or if you are using jQuery $.inArray("John", arr)
  24. Hmm, this is a common task, are you putting the values in an array just for this? If so, don't do that. Just check in your loop. If you already have an array, then you can use Array.prototype.inArray = function (value) { var i; for (i=0; i < this.length; i++) { if (this[i] === value) { return true; } } return false; }; now just do array.inArray("value to find");
  25. I think i found a great example http://www.openjs.com/articles/ajax/ajax_file_upload/response_data.php they use the hidden iframe but load the data back in JSON to get easily. I like this way a lot.
×
×
  • 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.