Jump to content

MPeter

Members
  • Posts

    21
  • Joined

  • Last visited

    Never

Everything posted by MPeter

  1. Hello, abdbuet. Before you do work with date and time - which is in fact a confusing thing - you should call this thing likely: @setlocale(LC_ALL,'de_DE@euro','de_DE','deu_deu'); ps: And read up all available methods on time-editing! It will be helpful as it stands in my rememberence. Regards, MPeter
  2. Hello, PHP Freaks, and -- Dear TLG! Under "Attach" you are going to find two files. 1) note.php 2) note.xml (*.xml is not uploadable) <note> <userstatcontent>?some=text</userstatcontent> </note> Just copy them into the same folder. Have a look at them. Their task is to log user activity any "x" seconds (till a runout). One of the next steps is to add window.innerWidth and window.innerHeight, and the use of Javascript-Cookie to save at least some of the data locally. This logging got me this early morning (here), and am really keen on to push it a little and come to some state where I can add it to my own site. ps: The final idea was done by TLG, and again a Big Thank You here - for inspiring me so much! Regards, MPeter [attachment deleted by admin]
  3. Hello, again. First, sorry for triple-posting. But no-one else did post something with code so far. And as I said here this is my first workaround about. Hey! I need a few more counts on my posts when I see 5,000+ on some users. j/k File #1: <html><head> <title>This File has a Title!</title> <script type="text/javascript"> var i = 0; function UserXMLHttpRequest () { if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp=new XMLHttpRequest(); } else {// code for IE6, IE5 xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); } xmlhttp.open("GET","note.xml",false); xmlhttp.send(); xmlDoc=xmlhttp.responseXML; MyTimestamp= new Date().getTime(); document.getElementById("userstatcontent").innerHTML= 'Hello ' +xmlDoc.getElementsByTagName("userstatcontent")[0].childNodes[0].nodeValue +'&mtime='+MyTimestamp+' World!'; i = i + 1; // :-) if (i < 9) window.setTimeout("UserXMLHttpRequest()", 10000); } </script> </head> <body onload="javascript:UserXMLHttpRequest();"> <h1>Test-File</h1> <p><b>userstatcontent:</b> <span id="userstatcontent"></span></p> </body> </html> File #2: <note> <userstatcontent>?some=text</userstatcontent> </note> It is based upon the Tutorial from here (with minor changes so far): http://www.w3schools.com/xml/xml_http.asp Well, I think things like window.innerWidth and window.innerHeight - which may change by some reason - can be added easily to this coding. Respectfully all the data which will appear, the use of a Javascript-Cookie I do see as recommended. These are the things I will try to add for myself next. When someone has any additional ideas and resources to link - please - do not hesitate, I got really greedy about this here, and I feel there must be something more than only this! ps: Thank you for inspiring me so much. It was a very long time ago I have read such a beautiful description, really. And my native language is not english. A Big Thank You! It was great fun to read up these technical things once again, and to write something useful (for me). And I do hope I could have given an answer. Regards, MPeter
  4. This here should do it. <span style="white-space:nowrap;">Your long text, with a lot of text, and even more text</span>
  5. Hello again! Huh? Sorry for double-posting. But after having breakfast and a shower here I think I will integrate that idea to my site as well! Though! I have a few Javascripts through now, and I am into these files now: http://www.w3.org/TR/XMLHttpRequest/ http://www.w3schools.com/xml/xml_http.asp I think am going to post my first working result later on. Well my wife is awake, and it is nearly the local time for lunch here! And onions get not cut by themselves. *cough* Regards, MPeter
  6. Hello, LimeMonster. All have to start one day, right. Start with a book called: PHP for Dummies (Best Way is to go to your local book store and order it there to help your local economy instead of some WTF-commerce) My rememberence reminds me that it does have "Login, Member, etc. pp." in description in it. ps: Then have a travel with a train - a few hours - to a nearby city! Read it up onwards. So you can dive into the material freely. That'll be a good start. And have a good tea or coffee there. Regards, MPeter
  7. Hello,The Little Guy. Perhaps the following JavaScript methods would be of interest for you: setTimeout() clearTimeout() I think the rest is obsolete because of your rank? Regards, MPeter
  8. It was more a personell thing here, you know. My neighbours wife had an old computer, sadly she passed away two years ago by cancer, and she was using Windows for Workgroups 3.11 on a very old machine. I felt writing anything for her, too, the fact we had very good contact over the fence ... But let me crop and translate a part out of the above document: height: 1em; /* Workaround gegen den 3-Pixel-Bug des Internet Explorer bis Version 6 */ It says that there is Three-Pixel-Bug below Version 6 on the IE, and that line solves it. Regards, MPeter
  9. Hello, esandra. So you want to have menu? A drop down? Menu? With sub menus? Or is that just missing pronomes in your text? With numbers in it? Am not sure about your description at all. But. As I do understand it you would like to have a JavaScript or AJAX menu? Right? Give Google a chance, I say. I did for you - see, I found that here for you, looks cool: http://www.webmonkey.com/2010/02/build_an_ajax_dropdown_menu/ Regards, MPeter
  10. Hello, khile. Look up here, too! http://www.w3schools.com/js/default.asp http://www.w3schools.com/js/js_ex_objects.asp http://www.w3schools.com/jsref/tryit.asp?filename=tryjsref_gettime The only thing the FORM does need to work could be that then: var servermicroseconds = <?PHP echo(microtime(true)); ?>; Have fun exploring! Regards, MPeter
  11. Hello, Justin. You wrote among other things: Generally your question shows your developing knowledge about PHP - bookmark these sites primarly: http://www.php.net/ http://www.w3schools.com/php/ Now to your question am going to summ up a few PHP-functions: is_dir() require() include() glob() Especially the last one could be of interest to you, but I strongly recommend that you do look up all of them on official PHP site: www.php.net Have fun! Regards, MPeter
  12. Hello, keram617. a) Do you use a shop-software? Or is your "shop" hand-written? When you do not have the permission to change code in the software, you know. License-Thing! b) As you did describe that you want to "store stuff to a MySQL with PHP", perhaps you could perfectly start here: http://www.w3schools.com/php/php_mysql_intro.asp Regards, MPeter
  13. Hello, "chrules". When you work on an CMS you really should work with MySQL as your first choice to store information beside. When you now start to save data into *.txt-files it will occur that you hang up your webspace by fact one "number of files" (when you do not correct the limitation on the *nix-system), fact two "webspace" because all the little *.txt-files with a few Bytes in it are above 1 KiloByte because of their file-start and file-ending which you do not get to see in the FTP-View, but the result could be that 1,000,000 *.txt-files of 200 MegaByte will consume 3-4 GigaByte of webspace. I hope I could give out a hint that you should start working with MySQL. On that a CMS is a Content-Management-System. My rememberence does not remind me that WORDPRESS is one, too. In my point of view WORDPRESS is more a WEBLOG (Web-Blog). Anyways! You want to have Stuff-commented, right? Work with MySQL - perhaps start here, it is a great source for: http://www.w3schools.com/php/php_mysql_intro.asp Regards, MPeter
  14. MPeter

    CSS Menu

    Hello, dezkit. How about you try out: http://www.cssmenumaker.com/ I remind this side doing exaclty what your tiny-picture does show -- generating CSS-menu like this. Regards, MPeter
  15. ...just for the records! They seem to lack a few information for old browser versions. Have fun to crop them out of here (look into sourcecode and commented area): http://de.selfhtml.org/css/layouts/anzeige/kopfundfuss.htm ps: Yes, it is in german, but I hope that is a minor problem nowadays. Regards, MPeter
  16. MPeter

    RESOURCES

    Very Great and Famous GERMAN & FRENCH website about HTML, CSS, JavaScript, and some server-side related, which is surfable in a really great catalogue! Main-Site: http://www.selfhtml.org/ German-Site with Search (= "Suche nach") -- Have a try! http://de.selfhtml.org/ ps: Google-Translate might help you out then when it comes to the facts.
  17. Hello, c_pattle. You wrote: You talking about the built-in method of a browser, don't you? Am not using IE except for looking at my own website, and that only because of its design and layout. So -- I suggest your acquaintance who is using the Internet Explorer might need to install an Extension. Or -- your XML-Feed is just too simple for the IE. I want to say that especially Microsoft, Yahoo!, and ASK.com do not work with minor-class-written XML-data. You can have a look on that case sitemap on www.sitemaps.org; when you do not write your sitemap in this syntax especially for ASK.com it will not work with your website in the case of sitemap. Just an idea. Would have been nice when you whould have posted an example of your feed, wouldn't it? ps: At all, try an XML/RSS-Feedreader to subscribe to your Feed - when that thing shouldnt do it, then there is something heavy wrong with your feed. Regards, MPeter
  18. Hello, Rich Hollenbeck. Well, you like to write that in PHP. But I do see more Client-Side work in Javascript for this. In my understanding, at all, it is normal FORM where all things seem to be hidden - running Javascript - they get revealed on click. Later on the analysis runs server-sided as in the language you have present. First you have your questions and answers on the website written out alike in <div style="visibility:hidden" id="questionone"> etc. pp. - so that they cannot be seen by the user. On-Click via Javascript they get revealed! For example like this: function numberone () { if (document.getElementById) document.getElementById("questionone").style.visibility = "visible"; } So you have normal form where you can "play" in JavaScript. There are a lot more things you can add in here now. I hope I could give out my two best cents! Regards, MPeter
  19. Try this here: a) Put a <span>-container around your area b) Do not allow wrapping via css <span style="white-space:nowrap;"> c) Play with the line-height via css <span style="white-space:nowrap;line-height:5em;"> Regards, MPeter
  20. Dear PHP Freaks, here my running code which does fine for now: Options +FollowSymLinks RewriteEngine on RewriteRule ^([^/]+)$ index.php?q=$1 [QSA] But it is ment to be a virtual folder instead of what it does to be a virtual file! Second, it has a problem that it does submit q= two times when you look at the $_SERVER['QUERY_STRING'] - e. g.: QUERY_STRING: q=index.php&q=Y-m-d And I do not get it why. Still, debugging it shows that the code does run fine: root@ubuntu:/tmp# more rewrite.log 127.0.0.1 - - [28/Oct/2010:19:16:56 --0700] [localhost/sid#218d7c58][rid#21a95400/initial] (3) [perdir /var/www/] strip per-dir prefix: /var/www/index.php -> index.php 127.0.0.1 - - [28/Oct/2010:19:16:56 --0700] [localhost/sid#218d7c58][rid#21a95400/initial] (3) [perdir /var/www/] applying pattern '^([^/]+)$' to uri 'index.php' 127.0.0.1 - - [28/Oct/2010:19:16:56 --0700] [localhost/sid#218d7c58][rid#21a95400/initial] (2) [perdir /var/www/] rewrite 'index.php' -> 'index.php?q=index.php' 127.0.0.1 - - [28/Oct/2010:19:16:56 --0700] [localhost/sid#218d7c58][rid#21a95400/initial] (3) split uri=index.php?q=index.php -> uri=index.php, args=q=index.php&q=100 127.0.0.1 - - [28/Oct/2010:19:16:56 --0700] [localhost/sid#218d7c58][rid#21a95400/initial] (3) [perdir /var/www/] add per-dir prefix: index.php -> /var/www/index.php 127.0.0.1 - - [28/Oct/2010:19:16:56 --0700] [localhost/sid#218d7c58][rid#21a95400/initial] (1) [perdir /var/www/] initial URL equal rewritten URL: /var/www/index.php [iGNORING REWRITE] As you see this coding above badly needs optimiziation. I hope I did describe the two problems to the best as possible, and that you can help me out without pointing me into cheatseets or the official httpd site. I got a few through already, and that is the result of them - *smile* Big thank you. Regards, MPeter (New PHP Freak User)
×
×
  • 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.