Jump to content

Zane

Administrators
  • Posts

    4,362
  • Joined

  • Last visited

  • Days Won

    11

Everything posted by Zane

  1. Yea, because answering a hypothetical question is like practicing to propose marriage; you never know what will be said and you can wonder about it for the rest of your days, or just do it.
  2. Where are you declaring $option. Either those properties do not exist, as the error suggests, or ... something else.
  3. That's just weird. Did you try clicking the little switch icon to turn off WYSIWYG mode? Try to edit something, turn it off, then cancel, and try to edit it again.
  4. Use Chrome and check your Debugger (F12).. something's bound to be red.
  5. Sorry, I can't seem to reproduce what you described. Anyone else experiencing this? Chime in.
  6. I moved it. Your question had nothing to do with code, I assume. You were asking a systematic question, in other words... application design.
  7. Zane

    Where Am i?

    wlcm tpo teh forms.
  8. Are you using the latest version of IE? Perhaps it was updated with a small bug?
  9. Speed is measured in meters per second; you will have to convert otherwise. You will also have to reverse your formula. speed = distance (meters) / time (seconds) CroNix is correct. This can all be calculated within the query, but you cannot subtract time without using the built-in MySQL functions for doing so. http://dev.mysql.com/doc/refman/5.1/en/date-and-time-functions.html In your case, i would go with cronix' idea of using TIME_TO_SEC()
  10. Probably a caching problem with your browser settings. Do problems similar to this occur on other websites? I can't recreate your error. Try pushing Ctrl+F5 to reload the cache, see if it works. If no one else is experiencing this then it is most likely on your end.
  11. Win8 systems are typically using UEFI http://www.howtogeek.com/175649/what-you-need-to-know-about-using-uefi-instead-of-the-bios/ So that may or may not be an issue. Let's find out. Turns out that UEFI is a big deal, but can be dealt with.
  12. You have to update the variable, not reassign it every loop. $site .= "The current loop";This will concatenate the $site variable instead of overwriting it. $site += 333If you are using numbers then this will increment the value. It's all in the manual.
  13. There are a plethora of GlobalEventHandlers that you can use to track activity using Javascript. https://developer.mozilla.org/en-US/docs/Web/API/GlobalEventHandlers - Clicking - Scrolling - Window Resizing - Scrolling - and so on and so on. Javascript is a very powerful language and it will be your best bet for checking authentic activity. Unfortunately, all of these actions can be overridden, and fake instances of showing activity can be triggered with curl and other site scraping libraries as well as browser plugins. The idea of triggering an AJAX request on every single one of these actions though is a bit daunting. So you might end up tweaking the your heartbeat script to set Interval times. You can continue to detail and microengineer what you consider to be the perfect activity checker. Then there are those not using JavaScript. To hell with them. Unless you're just meandering your way through the dirtiest alleyways of the intertubes, there is no reason to keep Javascript disabled. For them, I would just set the session expiry time to something small. Log them out. Make their experience miserable. Read through the various event handlers provided in the link and you may get some ideas. https://developer.mozilla.org/en-US/docs/WindowEventHandlers.onbeforeunload Phishing enthusiast tend to take advantage of all of these events which is why I mentioned digging through the dark and lonely alleys of the internet. It's also the perfect marketing tool. You can tell where people are clicking, how many times, the standard deviation of scrolls and hovers over texts. The possibilities are endless. Technically, you could also grab the users permission to "view" through their webcams and "listen" through their microphones. Open up facebook, open the network inspector by pressing F12, scroll through the page, hit buttons, click around, chat with someone, you will instantly see all of the AJAX requests firing away. Keep in mind though that Facebook has a massive massive userbase and therefore an even more massive server infrastructure. In other words... Facebook's servers can handle that many requests while others may succomb to DDOS problems.
  14. TurboSMTP probably removes all of your headers and creates their own to use according to the headers you provided. Having just looked over their documentation http://www.serversmtp.com/sites/default/files/turbosmtp-dashboard-handbook.pdf [on Page 16] You will see that in order to send HTML emails, you must create your template from your online account. This is what led me to assume that they strip your headers; that, and the fact that Googlemail worked fine.
  15. My vehicle 'doesn't work' either. Try and guess why?
  16. You have to forward port 80 to 443; the secure port. Follow this tutorial http://wiki.centos.org/HowTos/Https
  17. Yes, why? I would ditch the spaces, until you actually want to display the data.. otherwise, it's just a pain in the ass. You can query without the hassle of spaces SELECT * FROM vehicles WHERE plate_number LIKE '%f35%' To display the plate number with the spaces, just convert the string to an array and implode it by string. $str = implode( " ", str_split('fff3333') ); echo $str;
  18. In the manual page for str_getcsv, it provides an excellent example of how to get started; in the first comment. $csv = array_map('str_getcsv', file('data.csv')); You will then have an array with all of the names Also, in the manual, for the function array_multisort, there is another example. foreach ($csv as $key => $row) $lnames[$key] = $row[2]; array_multisort($lnames, SORT_DESC); With their powers combined, you can create this $csv = array_map('str_getcsv', file('csv.csv')); foreach ($csv as $key => $row) $lnames[$key] = strtolower($row[2]); array_multisort($lnames, SORT_ASC, $csv); echo "<pre>", print_r($csv), "</pre>"; $csv is now sorting in ascending order by last name.
  19. You're missing a closing brace $clientFeatures = DB::table('features')->join('clientFeatures', function($join) use($clientID) { $join->on( 'clientFeatures.featureID', '=', 'features.featureID') ->where('clientFeatures.clientID', '=', $clientID); })->get(); $groupIDs = array(); foreach ($clientFeatures as $c) { $groupIDs[] = $c->groupID; } } catch
  20. Content, content, content. The key to SEO. There are several, and I mean several, other factors involved (with search engines today), but content is the number one source of information. By content, I means words, lots of words, like enough to fill a few blog entries. For ecommerce sites, the product information, and most importantly the name and descriptions will draw in the traffic.
  21. SELECT UNIX_TIMESTAMP( datetime field); This will cause your database to work harder though, especially if you have thousands of records. Mysql's DATETIME datatype is the better alternative, it will allow you to perform complex date calculations much faster. otherwise you will have to convert all UNIX TIMESTAMPs to a mysql date format before performing any kind of the date functions provided by MySQL. Granted, though, NOW() will give you the server time, while the UNIX Timestamp will give you seconds since the epoch.
  22. SELECT DATE_SUB(OrderDate,INTERVAL 1 HOUR) AS SubtractDate FROM Orders
  23. Just echo out the PHP variables into your Javascript. var sender_id = <?php echo $sender_id; ?>; var receiver_id = <?php echo $sender_id; ?>; var message = <?php echo $sender_id; ?>; You can create JavaScript from PHP, but not the other way around. PHP is parsed FIRST. You can have PHP output whatever you want, anywhere you want. pretty much.
  24. it was saying thread_id wasn't a defined index because you were echo-ing out the thread_id get variable. You also commented out the if (isset) portion. So it seems the answer is that thread_id isn't being passed when you seem to think it is. If you plan to use the same value on multiple pages, it's best to use the actual tool for that task... $_SESSION.
  25. It's not going to be as easy as getting the average of the two colors. You're going to have to convert to something like CMYK/HSL/HSV and so on, perform some extremely complex algorithms, and get a result that you would then convert back to RGB. (hex) Your best bet, and easiest alternative without re-inventing the wheel is to find a jQuery plugin that can do it for you, such as this one http://www.xarg.org/project/jquery-color-plugin-xcolor/
×
×
  • 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.