Jump to content

JonnoTheDev

Staff Alumni
  • Posts

    3,584
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by JonnoTheDev

  1. And the price of beer is ridiculous! It was when I went to Copenhagen anyway.
  2. Try this <?php function replaceTag($string, $vars) { foreach($vars as $tag => $value) { $string = str_replace('['.$tag.']',$value, $string); } return $string; } $vars = array('memberName' => 'Susan', 'memberAccount' => '123'); $content = "Hello [memberName]. Your account number is [memberAccount]."; $statement = replaceTag($content, $vars); echo $statement; ?>
  3. There will have to be a degree of moderation. So, you will obviously approve the classifieds before they go onto your website (otherwise you will end up with spam). This is where you can check the data. In the process where a user submits a classified you could first get them to navigate to the location where the ad will appear rather than selecting from a drop list, so I would click on UK -> Manchester. If my location is not listed then I could suggest it at that point to go into the current screen i.e Prestwich (UK -> Manchester -> Prestwich). If you look at DMOZ again, when I am on the following page I can submit my url http://www.dmoz.org/Regional/Europe/United_Kingdom/England/Manchester/Prestwich/ by clicking the suggest URL link.
  4. You never stop learning with any language, even after 5 years. I would say that you should be able to create a simple website such as a blog after a few weeks of learning through books, tutorials, etc When you look back at the work you did when you started learning it certainly makes you cringe. I started off modifying existing websites. I can't really remember building my first application from scratch but it will be terrible. It's all part of the learning curve.
  5. Why not let the users do it for you. Start off with countries. Let the users enter the states / regions / locations etc. Just as DMOZ does http://www.dmoz.org/Regional/ If a location has already been created then another user can select it also. You would not want classified ads at a state level. States / regions / counties are far too large an area. Fo instance if I wanted a classified in the UK I would not want it placed in UK -> Greater Manchester. The area is far too large. I would want UK -> Greater Manchester -> Manchester -> Prestwich. You could go even deeper than that with the way other countries are divided. Look at the breadcrumbs on this page: http://www.dmoz.org/Regional/Europe/United_Kingdom/England/Manchester/Prestwich/ Also look how deep this page is for Wyoming in the state of West Virginia USA. It also goes deeper into towns. http://www.dmoz.org/Regional/North_America/United_States/West_Virginia/Counties/Wyoming/
  6. Yes. The website that you have put in your OP http://www.adhitz.com/en/Register has all the US states in the source code. I could scrape this and structure it in 5 minutes. I do not understand why you would want this for all countries just for a registration form. Countries are not all split into states like the USA. The UK is split into counties, other countries are split by provinces or regions and some places overlap regions, etc. If you are going to do this for every country then it is a big job, there is no getting away from it. I have done this before going right down to countries -> regions -> cities -> towns -> suburbs. The best free place to get this data is Wikipedia. Even if you pay for the data there is no guarantee that it will be correct.
  7. Just find a website that has it on. View the HTML source and scrape the data. Simple.
  8. Simple answer: Paypal
  9. I got this email [attachment deleted by admin]
  10. Yeah its hung but looks like Clegg is going to make a deal with Cameron. Clegg hates Brown.
  11. Seems like a decent budget amp. Has 2 speaker outputs. Speakers around the same price should be fine. You don't want to be buying speakers that cost 3 times more than the amp. http://www.amazon.co.uk/Pioneer-140w-HiFi-Speakers-Black/dp/B00005OOJN/ref=pd_bxgy_ce_img_c
  12. Looks like David Cameron will be running the country. We are all doomed! Kiss goodbye to our jobs.
  13. As I stated, run the collation query after you connect to the database. This is not going to fix html entities currently in the database but it will prevent more being inserted (if this is the script you insert items to the table). If you do not want to run the query every time you connect to the database then set the encoding to UTF-8 in your mysql configuration on the server. <?php // connect to database mysql_connect($db_server, $db_user, $db_password) or die(mysql_error()); // set encoding mysql_query("SET NAMES UTF8"); ?>
  14. You have added an extra paramater on the end, that is why! (pid) Here is the correct rule RewriteRule ^photos/([a-zA-Z0-9]+)/([0-9]+)/([0-9]+)\.html$ photos.php?name=$1&cid=$2&pid=$3 photos.php?name=text&cid=1&pid=1 Will become http://www.domain.com/photos/text/1/1.html
  15. Agreed. It's definately something that you have to spend time looking into thoroughly before making a decision.
  16. OK, when you connect to your database you must set the encoding. You do this via: mysql_query("SET NAMES UTF8"); You must do this prior to any insert query as I said best after connecting to the database. You can also set the character encoding in the mysql configuration. http://forums.mysql.com/read.php?103,46870,47245
  17. You have the same rewrite rules for different files! Prefix them with something to make them different. RewriteRule ([a-zA-z0-9]+)/([a-zA-z0-9]+)\.html$ artwork.php?name=$1&cid=$2 RewriteRule ([a-zA-z0-9]+)/([a-zA-z0-9]+)\.html$ photos.php?name=$1&cid=$2 i.e. RewriteRule ^artwork/([a-zA-z0-9]+)/([a-zA-z0-9]+)\.html$ artwork.php?name=$1&cid=$2 RewriteRule ^photos/([a-zA-z0-9]+)/([a-zA-z0-9]+)\.html$ photos.php?name=$1&cid=$2 Change the urls so they match the rules. Also dont start a rewrite using ([a-zA-z0-9]+) As it allows any alphanumeric text it clashes with your other rules. Again, prefix with a string of meaning as above.
  18. Absolutely. IMO A degree is worth pursuing if you are guaranteed, or have a good chance to find work in your area of study that a person without a degree cannot. Also I would expect a level of pay higher than that of non-graduates. If your area of interest is looking more towards experience then I would most definately not go down the degree route and opt for a work based apprenticeship scheme if available. This would mean starting on a low wage but gaining valuable experience along with doing a recognised qualification. When I left school in 1997 I chose to do an apprenticeship in Web Development. Not going to university was the best choice I ever made. I have friends who went to university and are way behind in my eyes, plus they have a large debt that they will be paying off for a long time.
  19. It depends on what you will be using it for. TV, DVD, Music, Games Console? If you are going to be using all or most of these then you are better going for an AV receiver. This is basically an amplifier that has inputs for HDMI, etc. It can upscale DVD and TV, and produces a superior sound quality. With something like this then you would never use 2 speakers, maybe have 2 bookshelf speakers but you would have around 6 small speakers that give you surround sound along with a subwoofer for bass. You can end up spending a lot of money here, however there are some bargains. Note, speakers come separate. http://www.richersounds.com/product/av-receivers/onkyo/txnr1007/onky-txnr1007-blk If all you require is for music i.e plugging your iPod in or computer then you could just get a decent amp and a couple of speakers. http://www.richersounds.com/product/amplifiers-receivers/denon/pma510ae/deno-pma510
  20. No, this is not the case at all. All my graduates did Software Engineering and mostly chose modules in Web Development. None were from a Computer Science degree. My argument is that what they had learnt over the 2-3 years of their degree within the web development modules did not even scratch the surface of what skills are required in the real world. It took a lot of time to train them up to the standard where they could work on a clients project. This is why I have the opinion that experience is more valuable than a degree and seems to be the opinion of current employers.
  21. Yes, I totally agree with this. It does depend on the type of degree against the job in question. The graduates that I employed had done their degree in software engineering, not just a generic computer science degree, however the modules that they had chosen had mostly all been web development. They had achieved good grades and were keen to work however I was stunned at just what they had been taught on their course. It just didn't scratch the surface in the real world. Our graphic designer had much better results as he chose graduates from graphic design courses. They were able to hit the road running without issue. I think with the current climate companies want to employ people who can hit the road running and get straight on with the job as opposed to spending time training. This is especially true with a small company like ours, so experience will always take priority over a degree.
  22. And this will be the case in most industries within the UK. The bottom line is that there are just too many graduates going for the same jobs. I sypmathize with you as it is tough. Most of the graduates that I employed we ended up paying them a really basic wage as they just did not have the knowledge or experience to justify higher pay. They could have been earning a similar wage in the same job without the degree by being self taught and would have gained the experience. If I had just finished University I would expect to get a well paid job, better than the pay that someone without a degree would earn. However, this just isn't the reality.
×
×
  • 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.