Jump to content
UBot Underground

Is there a way to make a Comparison between the page date and the system date


Recommended Posts

Hi.

 

first you have to scrapte the date from the page into a variable. 

Maybe you also have to convert it. So that you can compare it correctly.

 

You can get the system date with the following plugin:

http://www.ubotstudio.com/forum/index.php?/topic/13665-free-plugin-datetime-manipulation/

 

Hope that helps a little bit.

 

Cheers

Dan

Link to post
Share on other sites

u dont need  a plugin  ubot has default a $date function inside  use it with a regexmethode and u got what u want

set(#myyear$find regular expression($date"[0-9]\{4,4\}"), "Global")

Link to post
Share on other sites

If date/time format on the page is in the same format as UBots $date then you can just go ahead and compare them directly, if not, I think you'll find the DateTime Manipulation plugin helpful, since for comparison you'll want to convert both times to UNIX time-stamp before comparing them.

 

Here is an example of comparison:

http://ubotdev.com/free-plugin-datetime-manipualtion#compare-two-unix-timestamps-to-get-time-difference

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...