Part of the EllisLab Network
pMachine Pro has been replaced by ExpressionEngine, our full featured web publishing solution. Please consider upgrading.
You can download pMachine Pro here: Download pMachine Pro  |  Download Language Packs
   
 
Required Fields in Entry form
Posted: 14 January 2006 12:00 PM   [ Ignore ]  
Summer Student
Total Posts:  2
Joined  2006-01-14

I am new to pmachine (v 2.4) and I am currently designing a collective weblog entry form.

I notice that pmachine requires the user to enter a title and put something into the body.  Does anyone know a hack for making it also require the user to select a category?

I’ve tried to work through the code, but I can’t even figure out where it checks to see that the title and body fields have been populated.  Any suggestions would help.

Thanks

Profile
 
 
Posted: 18 January 2006 09:35 PM   [ Ignore ]   [ # 1 ]  
Summer Student
Total Posts:  2
Joined  2006-01-14

In case anyone is wondering, I figured it out.  The required fields are validated in the lib/weblog.add.php.  On line 410 there are two variables listed: $title and $body.  To make the category a required field, just include $catid=="” in this list.

Profile
 
 
   
 
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 233, on December 18, 2007 12:04 AM
Total Registered Members: 61024 Total Logged-in Users: 0
Total Topics: 73808 Total Anonymous Users: 0
Total Replies: 398133 Total Guests: 38
Total Posts: 471941    
Members ( View Memberlist )
Newest Members:  b-rodMAIDENtreatstruckaungAdrian LeonP.T.Aoochoi2kfantomelIfTrueElseFalse
Active Members: