Jump to content

abazoskib

Members
  • Posts

    548
  • Joined

  • Last visited

    Never

Posts posted by abazoskib

  1. what if you have a table called "from"? a statement like "SELECT * FROM from" will not execute. "SELECT * FROM `from`" would work.

     

     

    I doubt it if you can name a table "from", I think "from" is a reserved word in MySQL, therefore your example is not even right to begin with.

     

    Do you doubt this from your extensive knowledge of databases and in particular mysql? Please. Why don't you try it yourself. "create table `from`(test int primary key)". That's exactly why you would use ` because IT IS A RESERVED WORD.

     

     

    excuse me, my knowledge is not extensive in SQL, I have not written any SQL statement in ages, however, why would a reasonable programmer give a table such name? a reversed word? don't tell me that he ran out of words lol.

     

    This way he is forcing himself to use this ` in each and every statement in his SQL's which sucks.

     

    Anyway, you need to take care of millions of web sites that have their SQL's without ` and convience them all to rewrite their code or look for every piece of SQL in their code.

     

    good luck for those who want to put ` in their SQL, I promise I won't put any lol, in fact I don't even write SQL's but even if I have to, I won't because its ridiculous.

     

    It basically only sucks ONCE when you write your application. "from" would seem like a popular table name choice to me, even though i personally wouldn't use it. its also comparable to using {} to mark variables within a PHP string i.e. $mad_lib = "The bread basket was full of {$adjective} bread..." Some people dont do it, or dont like it, but I like it because its easier to pick apart variables just by scanning it quickly. Same with `

  2. what if you have a table called "from"? a statement like "SELECT * FROM from" will not execute. "SELECT * FROM `from`" would work.

     

    I doubt it if you can name a table "from", I think "from" is a reserved word in MySQL, therefore your example is not even right to begin with.

     

    Do you doubt this from your extensive knowledge of databases and in particular mysql? Please. Why don't you try it yourself. "create table `from`(test int primary key)". That's exactly why you would use ` because IT IS A RESERVED WORD.

  3. Hi,

     

    I've been doing some really poor PHP for about 3-4 years now and with the new year, I want to do it the better way :)

     

     

    What are you talking about? The "better way" has nothing to do with changing perfectly fine functional code into an OOP class. Don't use OOP because you think its advanced. Use it when you need to. Understanding this will make you that much more of a better programmer.

  4. Its actually not as caveman like as Garethp suggests. You can trademark your logos, or slogan, and such. You can also put up a copyright notice, a privacy policy, and look into a trade dress. http://smallbusiness.findlaw.com/trademark/trademark-domain-names/website-appearance.html

     

    The thing about competition is who has the better appeal. If you are confident in your product, I suggest you get a partnership going so you can handle how it grows. Finances, development, and logistics are all departments you'll want to cover but not all by yourself. A great way to stay on top of the game is to have a team that's ready to meet the demand.

  5. if you dont need the body of the response, a good setting to set to true is CURLOPT_NOBODY, however i think since you are downloading webpages that might not be useful. try it, but other than that i think it has to do with your server's internet connection, and that of the sites you are downloading from. without much more detail from you thats all i can think of.

  6. Well we are shutting that server down and going with godaddy servers is this a good idea???

     

    godaddy has been terrible in my experiences. although im sure if you go with a dedicated machine you should be ok. do not use their shared server. make sure to use a really good password because godaddy ssh accounts get brute forced all the time.

  7. set your footer image to no repeat. i see two of them. also the grid/tech look is a bit cheesy. try lightening the text on your buttons. there's too much contrast and the text doesnt look to be a part of the button. if i were you id scrap the forum idea and go with a much more lightweight live messageboard system.

    I'll see what i can do about the footer image. I think thats due to the copyright image being there to so i might remove that.

    Erm which buttons are you talking about? The navigation bar isn't supposed to be buttons the image is just to separate the actualy links.

    Don't get what you mean by scrap the forum idea though.

     

    It's just an opinion but having a whole forum dedicated to your site might be overkill. There are many ways to build a simpler more lightweight message board that would be good enough for you to post events and such. Up to you, its just what I would do.

  8. set your footer image to no repeat. i see two of them. also the grid/tech look is a bit cheesy. try lightening the text on your buttons. there's too much contrast and the text doesnt look to be a part of the button. if i were you id scrap the forum idea and go with a much more lightweight live messageboard system.

  9. There are different ways to approach this. It all depends on your needs. You can do a simple POST/GET API like suggested above. You could also have a RESTful API where parameters get passed like: http://yourdomain.com/param1/param2/param3/ (this will need mod rewrite rules on your server). You can do a combo of POST/GET and REST by POST/GET to a URL like the one I showed above. You can also look into a SOAP server. There is VERY LITTLE documentation on this, and it was such a pain to setup the WSDL for it. I wrote one a few months ago which works really well, but be warned its very challenging. If I had to do it again I would use REST combo with POST/GET.

  10. You do not want to create a new object for every query. That is completely not the point of creating a class. Why odn't you create a class for a database object(connection and picking which database you want to use), then create methods within that class to perform different queries, and such. It's a hefty task to get all the functionality in there. You might want to check out sample code thats already been written. Don't reinvent the wheel.

×
×
  • 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.