Jump to content

Ayon

Members
  • Posts

    141
  • Joined

  • Last visited

    Never

About Ayon

  • Birthday 01/09/1984

Profile Information

  • Gender
    Male
  • Location
    Norway

Ayon's Achievements

Member

Member (2/5)

0

Reputation

  1. Yes that's correct except the paranteces should not wrap it all. It should be either ($month != 1) ? $month - 1 : 12; or $month != 1 ? $month -1 : 12;
  2. Ayon

    I'm back

    After not beeing here for a few years I've finally manage to stumble my way back in here Quick report about what my time has been spent on: - Family life, and my son just turned two. - Got myself a job as a system developer! My dream came true (even tho it was nothing like I expected at all) - Several dead-before-launch personal projects, which really isn't that new to me I've yet to complete a personal project hehe - and just learning learning learning the whole time. Hopefully I have som more wisdom with me that I can share on here Good to be back, even though probably there's noone here who remembers me at all Have a nice day everyone!
  3. Thanks a bunch for the quick reply AlexWD! This is a good example why I really enjoy this forum, even tho I'm not very active
  4. change this action="" to this: action="<?php echo end(explode("/",$_SERVER['REQUEST_URI'])); ?>"
  5. I've been trying to solve this issue for so long now.. I believe I'm close, but it's just the last part that I can't figure out how to solve.. I have a set of parsers and a controller. each parser is in it's own object named like Parsers_Imdb_Imdb.. What I want now is to be able to do this $parse = new Parsers; $imdb = $parse->Imdb->get_info('some random info'); So far I've managed to get into the Imdb parser object, but I 'm not able to grab the method. parsers.php class Parsers { function __construct() { } public function Imdb() { new Parsers_Imdb_Imdb; } } imdb.php class Parsers_Imdb_Imdb extends Parsers { function __construct() { parent::__construct(); } public function get_info() { echo "get_info()"; } } I've got a __autoload() to solve the class declaration.. Could anyone please help me out with this? Thanks in advance
  6. I've been trying to solve this for a while now, but still haven't had any luck. What I'm trying to do is this: $class = new BaseClass; $var = $class->load("subclass")->subclass_function("info"); Thanks in advance Ayon
  7. I'm trying to count all releases by an artist. But on the ones where artistname includes a '&' only returns 0 on my site, but in phpmyadmin i returns the correct number of releases this is the query i'm using SELECT * FROM hsdb_releases WHERE artist LIKE '%Brennan & Heart%' i guess it's cause of the '&' it's failing.. any suggestions on how to solve this? thanks in advance
  8. I was abit quick here... it's still not working as i want to i've got the following string {artist1} & {artist2} and i want to separate the to artists into an array so that i can link to each profile but for now it stores the whole string as one
  9. typical.. after trying for a days i found the solution right after i had asked the question Solution was here: http://www.smarty.net/forums/viewtopic.php?p=25287
  10. this is what i'm using.. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> </head> im using smarty as well.. can that be causing this conflict?
  11. I've just started working with AJAX, and I'm completely stuck on this... So hopefully someone's able to help me out Here's the AJAX code function rate(type) { if (window.XMLHttpRequest) { xmlhttp=new XMLHttpRequest(); } else { xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); } url="rel_rating.php?type=" + type; xmlhttp.open("GET",url,false); xmlhttp.send(null); document.getElementById('rategood').innerHTML=xmlhttp.responseText; } here's where i'm trying to output the result: <span id="rategood">{$relRateGood}</span> <a href="#" onClick="rating('good')">{html_image file='images/thumb_up.png' border='0'}</a> <span id="ratebad">{$relRateBad}</span> <a href="#" onClick="rating('bad')">{html_image file='images/thumb_down.png' border='0'}</a> the "rel_rating.php" only contains this <?php echo $_GET['type']; ?> Thanks in advance
  12. I've been trying for a while now to get this regex to work, but i still haven't been able to get anything else than the curly brackets could anyone please help me out? $string = "test {id:5;name:Helbom}, test"; if (preg_match_all("/[\{(*.?)\}]/",$string,$matches)) { print_r($matches); } $smarty->display('index.tpl'); Thanks in advance
  13. wild guess $playerArray.{$match['activePlayer']}[26]
  14. yet again i really wanna thank you for taking your time to describe this so carefully and detailed man... i know I'm really learning alot of extremely useful things from this, and I'm sure alot of other people also finds your replies very useful!
×
×
  • 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.