gMagicScott / wordpress-plugin_amazing-system

0 stars 1 forks source link

nDate #19

Open gMagicScott opened 10 years ago

gMagicScott commented 10 years ago

Getting the ndate JavaScript to work correctly from the static Amazing System files can be problematic on some websites, although I'm not totally sure why.

Ultimately, I would like to integrate with Gravity Forms to allow it's easy form creation with the extra Amazing System functionallity added in.

In the mean time, we could use something like [ndate] within the form. On the page, that would turn into:

<input type="hidden" name="ndate" value="2/26/2014" />

Of course the value, 2/26/2014 in the example above, would dynamically calculate the correct date for 'tomorrow'.

twinsmagic commented 10 years ago

Could we also make add another for the countdown timer? Like this:

twinsmagic commented 10 years ago

oh I guess I can't add my line of code. Anyway it was the sames as yours except it was name="ndate1"

gMagicScott commented 10 years ago

Check out Markdown it's you can format text in these issues and include code.

Example -- the link above

Check out [Markdown](https://help.github.com/articles/github-flavored-markdown) it's you can format text in these issues and include code.

The part about code is here

gMagicScott commented 10 years ago

In full it could be

[ndate
    field="ndate"
    add="0"
/]

Those would be the defaults, so you could just use [ndate] by itself. To get the ndate2, you could use [ndate field="ndate2" add="1D"]

With add, I'm thinking

twinsmagic commented 10 years ago

that would be killer!