Jump to content

PatPHP

Members
  • Posts

    30
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

PatPHP's Achievements

Member

Member (2/5)

0

Reputation

  1. Hi Guys How can I get all the data from the current year??? I mean between 2009-01-01 and 2010-01-01??? I tried to do it with the time functions between year(curdate()) and year(curdate()) + 1. But this doesn't work. Thanks for your help.
  2. Cool;-) I found a solution;-) Just add a hidden field to the form and assign value to it before you send it;-) <form name="frm" method="post"> <input type='hidden' name='participations'/> </form> <button onclick="tlist2.update(); send();">Send</button> <script language="JavaScript"> function send() { window.document.frm.participations.value = $F('multiselectlist-demo'); window.document.frm.action = "get.php" window.document.frm.submit() } </script>
  3. Hi Guys I'm not very experienced with Javascript. But I found a pretty cool AJAX Script which allows text auto completion like you have seen in fb or google search. It's called Proto!MultiSelect. Now this script works perfect but the example page also only displays the values in a message box. How can I send this information via Post to a php webpage instead? Here test webpage: http://www.interiders.com/2008/02/18/protomultiselect-02/ If I press the Get Values button I want to send this values to a php page instead of showing it in a message box. Here the code if it helps: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> <title>Proto!MultiSelect Demo</title> <link rel="stylesheet" href="test.css" type="text/css" media="screen" title="Test Stylesheet" charset="utf-8" /> <script src="protoculous-effects-shrinkvars.js" type="text/javascript" charset="utf-8"></script> <script src="textboxlist.js" type="text/javascript" charset="utf-8"></script> <script src="test.js" type="text/javascript" charset="utf-8"></script> </head> <body id="test"> <h1>Proto!MultiSelect Demo</h1> <p><a href="http://www.interiders.com/2008/02/18/protomultiselect-02/">See article page</a>, <a href="http://www.interiders.com/wp-content/demos/ProtoMultiSelect/test.html">Go to Proto!MultiSelect demo</a></p> <div id="text"></div> <form action="test_submit" method="get" accept-charset="utf-8"> <ol> <li class="input-text"> <label>Simple input</label> <input type="text" name="testinput" value="" id="testinput" /> </li> <li id="facebook-list" class="input-text"> <label>FacebookList input</label> <input type="text" value="" id="facebook-demo" /> <div id="facebook-auto"> <div class="default">Type the name of an argentine writer you like</div> <ul class="feed"> <li value="1">Jorge Luis Borges</li> <li value="2">Julio Cortazar</li> </ul> </div> <!-- These two writers will be added when the control is loaded --> </li> </ol> </form> <div id="button_container"> <button onclick="tlist2.update(); alert($F('facebook-demo'));return false;">Get Values</button> </div> <script language="JavaScript"> document.observe('dom:loaded', function() { // init tlist2 = new FacebookList('facebook-demo', 'facebook-auto',{fetchFile:'fetched.php'}); // fetch and feed new Ajax.Request('json.php', { onSuccess: function(transport) { transport.responseText.evalJSON(true).each(function(t){tlist2.autoFeed(t)}); } }); }); </script> </body> </html>
  4. They would be all different kind of languages but aren't all url just in normal ascii code?
  5. I really like waterproof phpedit. Especially there is an ftp function which you can connect to the server and do all the programing straight away on the server. Don't know if something like this exist for eclipse.
  6. Hi Guys Is there a way in apache or php so I can handle the string after let's say. www.mydomain.com/searchme <---. Or is it just possible to handle the 404 error page error? thx
  7. so how can i run a more complex query that will tell me exactly? don't really understand what you mean. an example would be great. thx
  8. True actually 256 characters is quite long and will be long enough for my purpose. So I will limit it to that at the moment.
  9. At the moment I run all the statements separate and do the comparing in php. Works great so far but I'm sure it would not be the best solution. I just don't know enough about mysql yet. Anyway I try to explain in more detail what I try to achieve here and I hope I still will get a better solution. A member has a certain awards and if he want's to attend a training he needs to meet this awards. Here a simplified example: To be able to sign up for the training you need to have this awards: Swimming Dancing Singing User has: Swimming Dancing Surfing So the user would not be able to sign up because all his awards don't meet the training requirements. So my question is how can I make this comparison? If you look at my sql statement above it would work if this way would exist in mysql. I just want the mysql give a string in return when the user is able to sign up. I know it's a little bit complicated to explain over the web.
  10. @Crayon Violent That is interesting what you say. But it actually does give live output. I have a loop and in that loop an echo. It will give me the output on my browser. But it will just show me the output after 30-50 seconds regularly. I haven't figured it out yet why this is the case.
  11. Hi I'm developing on a program where many URLS will saved into mysql. Now my question is what is the best data type to use for that purpose so that it is still fast to access and requires not too much space? So varchar(2000) or text? Which one is faster and which one uses less space? Which collation is good for URLs? I won't do any search in them. I will just access them via id number. Thanks for your help.
  12. Strange... it does it now... after a while. Sorry thread can be closed.
  13. Hi How can i get a live output instead of running the code first and show everything rendered at the end?
  14. I have two select statements and I want to give back the record if awardsequal = tptotal. How can I do that? The first sql which I wrote here doesn't work. It is just an example how I would like to have everything together. I hope you can understand. SELECT * FROM training t JOIN member m ON m.id = '480' WHERE t.id = '30' AND ( EXISTS (@awardsequal= @tptotal))) SELECT COUNT(*) AS awardsequal FROM member_award ma JOIN training_prerequisite tp ON ma.awardid = tp.AwardID WHERE ma.memberid = 480 AND tp.trainingid = 31 AND tp.GroupNum=0 SELECT COUNT(*) AS tptotal FROM training_prerequisite tp WHERE tp.trainingid = 31 AND tp.GroupNum=0
  15. I tried for hours but could not find any solution in sql. Hopefully this example will help to explain. So what is the SQL Statement to find out if Member 'Pat' meets all the reguirements for 'Training 1'? Here an easier example of the DB: Skill ID Name 1 HTML 2 VB 3 PHP 4 Java 5 C# 6 CSS Member ID Name 1 Pat 2 Sandra 3 Rolf 4 Justin MemberSkill MemberID SkillID 1 1 1 2 1 3 1 4 Training ID Name 1 Training 1 2 Training 3 3 Training 4 TrainingRequirement TrainingID SkillID 1 1 1 2 1 3 1 5
×
×
  • 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.