View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Incremental Dates for each record

Thread began 5/27/2009 5:15 am by acaciasd344844 | Last modified 5/29/2009 11:26 am by acaciasd344844 | 1819 views | 10 replies

acaciasd344844

Once again thanks for your able assistance, I would not have got this far without you.


I have managed to get the dates to increment and figured out how the system is looping etc.

It just appears now that the date the code is supposed to increment is replaced by '1970-01-01', obviously a system start time.

I have been really trying to get this to work but my lack of php knowledge is rather telling.

this is what i have so far...


*** I put the variable above the begin loop section:


<?php $writeDate = $row_Recordsetcustomers['date']; ?>
<?php
// RepeatSelectionCounter_1 Begin Loop



*** I created a visible test field so that I can see the results before they enter the system. This sits with the hidden fields

<input name="textfield" type="text" id="textfield" value="<?php echo date ('Y-m-d H:i:s' , $writeDate); ?>" />



*** I put the final bit of code in the RepeatSelectionCounter_1 End section


<?php } // RepeatSelectionCounter_1 End Alternate Content
if(!$RepeatSelectionCounterBasedLooping_1 && $RepeatSelectionCounter_1_IterationsRemaining != 0){
if(!$row_Recordsetpayments && $RepeatSelectionCounter_1_Iterations == -1){$RepeatSelectionCounter_1_IterationsRemaining = 0;}
$row_Recordsetpayments = mysql_fetch_assoc($Recordsetpayments);
$writeDate = strtotime('+7 days', $writeDate);
}
$RepeatSelectionCounter_1++;


} // RepeatSelectionCounter_1 End Loop

All this works except for the fact that the $row_Recordsetcustomers['date'] is not picked up and incremented and the following code you provide previously
stopped the increment from working altogether...

$writeDate= strtotime ( '+ '.$row_Recordsetcustomers['frequency'].' day' , date('Y-m-d H:i:s' , $writeDate) );


could all this be something to do with the php version I have? Or do I need to use Global variables?

Sorry to pester, Ray, but I have to have this bit done by the end of this month (gulp).

Once again thanks in anticipation


john

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...