TMFKSOFT commented on a Snippet, PHP Dateify!  -  2 days ago
@sean Agreed I soon discovered that were showing the undesired result along with another issue. Im still working on it.
 Respond  
Hawkee commented on a Snippet, PHP Dateify!  -  3 days ago
I posted something very similar, but yours seems to be a bit more flexible: http://www.hawkee.com/snippet/9368/
 Respond  
sean commented on a Snippet, PHP Dateify!  -  3 days ago
I agree with the "over coding" statement but, this is certainly a good start. I urge looking further into the date() function (specifically the 'M' flag), as your last line could have been

Code

 

Also your suggestion about appending 'ago' will provide undesired results after 24 hours. (ex: May 22, 2013 ago).

Sidenote: I've made a similar function some time ago here, if you'd like a friendly reference :) I hope to see more PHP contributions!
 Respond  
MoshMage commented on a Snippet, PHP Dateify!  -  4 days ago
Not bashing on you, but you're overcoding. you could've floored the $stamp and then divide that value to get days, hours, mins and seconds. But i guess your way works as well :)
 Respond  
Hawkee commented on a Web App, MakeFirstMove.com  -  24 days ago
I would call this a web app rather than a PHP app.
tomi commented on a Snippet, Simple GuestBook  -  Jan 22, 2013
how to make the most recent post appearing first ?
zenx commented on a Snippet, pagiLinks() Pagination Function  -  Jan 13, 2013
Thanks, using this in one project
 Respond  
ProIcons commented on a PHP Script, ajax mysql chat  -  Jan 09, 2013
Though its buggy tested it out on the demo link
 Respond  
ProIcons commented on a PHP Script, ajax mysql chat  -  Jan 09, 2013
As far i analyzed its not a relay chat. Every message is stored into MySQL Database. So when you connect to the room you can see all messages has been sent to the room, My guess or you can see whatever is posted after your join... Its basically simple and neat. Haven't tested but from the code even its messy seems fine.
 Respond  
Hawkee commented on a PHP Script, ajax mysql chat  -  Jan 09, 2013
Would be great to see a demo.
SunnyD commented on a PHP Script, ajax mysql chat  -  Jan 09, 2013
Can you tell us a little bit about it? What's it connect to? How does it work? etc..
Having such a bland description isn't going to inspire many to check it out if we don't know what it can do.
jrharper commented on a Snippet, Dynamic Title and Meta Tags  -  Jan 07, 2013
hawkee,

I have the title part working on my site,I used [if($category) print $category; if($subcategory) print $subcategory; print $title;] so that it would diplay $title before anyone clicked on $category or $subcategory. The value of $title is Products, so it just prints after $category or $subcategory is clicked, so my title becomes Art($category)Products($title).

My problem is that each page is loaded inside of my header as page1.html. All listings on the page are from $category or $subcategory. I'm not sure how to go about getting the keywords part to work. I don't need keywords for every page, just $category or $subcategory.

Your welcome to look at my site to see what I'm talking about.

Thank You
Hawkee commented on a Web App, Regex101 - free regular expression tool  -  Jan 05, 2013
@Lindrian Great to see you back! The tool looks quite useful. I'll give it a try the next time I need to build a regular expression.
Hawkee commented on a Snippet, Dynamic Title and Meta Tags  -  Dec 11, 2012
@pleb If this is the case then aren't you using JavaScript to bring up each page?
 Respond  
pleb commented on a Snippet, Dynamic Title and Meta Tags  -  Dec 11, 2012
the point is that my site uses a single page name and #xyz to show different content (but really they are different pages), a lot of sites do this now in order to avoid reloading and displaying content faster. but the problem indeed is that this page has a unique meta data right now. these are really different pages, but they are all under a single php file. for example gmail does this too: https://mail.google.com/mail/u/0/?shva=1#inbox
 Respond  
Hawkee commented on a Snippet, Dynamic Title and Meta Tags  -  Dec 11, 2012
@pleb You'll probably need to reload the page with the anchor appended as a query string, but I'm not sure what your ultimate goal is. Anchors usually represent a particular point on a page and not a full page in itself. They're for browsers and not for spiders, so meta tags that are dependent on anchors don't make sense.
 Respond  
pleb commented on a Snippet, Dynamic Title and Meta Tags  -  Dec 11, 2012
Hello @Hawkee,

I found this code to get the anchor using javascript and cookies.

<script language="javascript">
query=location.href.split("#")
document.cookie='anchor='+query[1];

if (query[1] != "<?php echo $_COOKIE['anchor'];?>") {
window.location.reload()
}
</script>

<script language="php">
$passedaname=$_COOKIE['anchor']
</script>

But so now, how do I capture what is returned in the anchor and add it the my page name (index.php in get_meta.php so that it gets the full URL (index.php#home? should I define it inside $page = ?

thanks a lot!!!
 Respond  
Stew commented on a Snippet, Dynamic Title and Meta Tags  -  Nov 29, 2012
Wow thanks @Hawkee really nice snippet!!!
 Respond  
ProIcons commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 22, 2012
I'm not familiar with PITC. Can u provide me more information about it?
 Respond  
TMFKSOFT commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 22, 2012
ProIcons, You should have a go at converting mIRC scripts to PITC so I can intergrate an MSL Interpeter into my IRC Client XD
 Respond  
Hawkee commented on a Snippet, Dynamic Title and Meta Tags  -  Nov 20, 2012
@pleb You'll need to incorporate JavaScript to read the hash portion of the URL. That information is not sent to PHP. Here is some more information, http://stackoverflow.com/questions/940905/can-php-read-the-hash-portion-of-the-url
 Respond  
pleb commented on a Snippet, Dynamic Title and Meta Tags  -  Nov 20, 2012
Hi Hawkee,
Running in a problem as my page is unique but shows different content using the # tag: index.php#home , index.php#contact etc...
I got it working on index.php but can't figure out how to structure get_meta and the data file to make it look at #home instead of just index.php

Thanks for your help
 Respond  
ProIcons commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 19, 2012
Description Also Updated. All Functions are now accessible through $ Symbol like mIRC Style.
Be aware. They Opening and Closing Brackets () are required. Otherwise it will return the function name.
 Respond  
Hawkee commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 19, 2012
There you go.
 Respond  
ProIcons commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 19, 2012
Updated. Now Vars are $var(); style.
 Respond  
Hawkee commented on a Snippet, PITC Screenshots [PITC v1.1]  -  Nov 18, 2012
Neat idea. Save text to an image file.
 Respond  
sean commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 18, 2012
Yup @Hawkee is right. You'll want to make use of variable functions to pull this off correctly :)
 Respond  
Hawkee commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 18, 2012
Once you include this file $time will be set to the time that you included the file, but it will not change. So if you check it 5 minutes later it'll still reflect the original time.
 Respond  
ProIcons commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 18, 2012
Oh if i got it right, it should be fine now..

Edit:
i Made a test

Code

 

Before the fix, so the first value was 3 seconds behind. Now it should be fine.. if that was what you meant.
 Respond  
Hawkee commented on a Snippet, [PHP] mIRC Identifier Library : mIRC.lib.php   -  Nov 18, 2012
Wouldn't $time remain static upon loading the library?
 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.