Jump to content

tibberous

Members
  • Posts

    1,187
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by tibberous

  1. premiso, your way also works, I just think the other way is cleaner.

     

    Contexts could be used for other stuff too. Like $dollar could be referred to in a 'currency' context, that would automatically return '$'.number_format($x, 2);

     

    or maybe a string could be output in an html context, where html_entities are already applied.

     

    Its really just a short version of a function call.

  2. I am REALLY tired I have to type:

     

    $city = mysql_real_escape_string(trim($_REQUEST['city']));

    $state = mysql_real_escape_string(trim($_REQUEST['state']));

    ect...

     

    Its like 15 lines of copy and pasted crap everytime I have a form.

     

    Here is my idea - variable contexts.

     

    It would work like this:

     

    define context ":" ($x) {

    return mysql_real_escape_string(trim($x));

    }

     

    Then, instead of saying:

     

    $city = mysql_real_escape_string(trim($_REQUEST['city']));

     

    You could just use:

     

    $:city

     

     

  3. I am buying a house and want to setup a large camera system so I can see most of the rooms in the house at all times, as well as the perimeter of the house. I was thinking I'd need like 6-8 outdoor night vision cameras, 5-10 room cameras, that don't really need audio.

     

    I could get a complete setup for like $3,000, but I was thinking I might do better to get the main unit off newegg and then add the cameras as needed. Anyone ever set a system up?

  4. For jpegs and pngs and gifs I just use imagecreatefrompng, ect.

     

    There isn't a imagecreatefrombmp file though. There is a imagecreatefromwbmp, but that doesn't work with my bitmap, so I'm guessing it is for a different type of file completely.

     

    Does anyone know how to do this? I have a customer who really wants to be able to upload his bitmaps =/

  5. I'm getting an error that mysql_num_rows and mysql_result are undefined. Whats really weird is that mysql_connect and mysql_select_db are working.

     

    Any idea what would cause it? I'm running it on windows, set my extension directory and uncommented out extension=php_mysql.dll in the php.ini.

     

    Apache 2.0.63

    PHP 5.2

  6. I have an obituary system that can hook into any website with an external script include, it also has a funeral planning form and a contact form. It's used by like 250 funeral homes right now, but so far my company has generally been sticking it on sites we've done.

     

    I was thinking about either offering it to existing web designers - it's only for funeral websites, but anyone who knows html web design can use it, and the prices on funeral home websites tend to be higher than most other fields.

     

    I was thinking:

     

    - Webdesigner calls funeral home, shows examples of their work and my system, gets a sale.

     

    - Webdesigner get sale and upfront payment, I create the account, they install it on the new site.

     

    - They either pay for a membership to the obituary system, or they leave that up to the funeral home (it works either way, membership unlocks some features)

     

    - Webdesigner gets their money for the site. They are happy they didn't have to code/pay for an obituary system and forms -- I'm happy because another person has the obituary system, which makes money off of memberships and advertising.

     

    Here is an example of the system added to a site:

     

    http://steelandwolfe.com/obituaries.htm

     

    What do you guys think of the idea? I thought of tweaking it and putting it on hotscripts, but it isn't really a script, its a hosted solution -- and I need people to offer it, because funeral directors aren't going to be on hotscripts making their own sites.

  7. I think I have one, ns1.trenttompkins.com and ns2.trenttompkins.com. They are setup by CPanel / WHM, but they work, because that is what I use for my sites.

     

    I just can't find any information about setting up and managing a DNS. I read the "How DNS servers work" on howstuffworks, but it is all conceptual.

     

    Apache has this record already setup in the httpd.conf:

     

    <VirtualHost *>

        ServerName server.trenttompkins.com

        DocumentRoot /usr/local/apache/htdocs

        ServerAdmin root@server.trenttompkins.com

        UserDir disable

    </VirtualHost>

     

    So it looks like it is set to turn all requests for unknown domains to that? But the DNS just isn't resolving them?

     

    Any idea how I get in and change the DNS?

  8. I want to make a CMS that people can go to and it will set them up a site (ie: mycms.com/tibberous)

     

    But I want people to be able to buy domains and point them to their CMS. How can I setup my server so it handles it dynamically? So someone can go in, enter tibberousawesomesite.com, and my server will point tibberousawesomesite.com to mycms.com/tibberous.

     

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