Jump to content

daslicht

Members
  • Posts

    5
  • Joined

  • Last visited

daslicht's Achievements

Newbie

Newbie (2/6)

1

Reputation

  1. I also have a pagination issue here and created teh following test setup: Essentially I have the following 6 pages: About Site Map Admin MyArticle News Gallery the homepage template looks like this: <?php $results = $page->children("limit=3"); $pagination = $results->renderPager(); echo "<ul>"; foreach($results as $result) { echo "<li><a href='{$result->url}'>{$result->title}</a></li>"; } echo "</ul>"; echo $pagination; The displayed result looks like this: About Site Map Admin 1 2 Next So the paginator is rendered properly, but when I now click on one pagination link the page just refreshes? Do I have to implement the pagination logic myself using pageNum ? ~Marc
  2. Thank you ! I play with the api functions now.
  3. Thank you very much for your extensive answer! Looks great ! But how would I save things with the relations I mentioned above, please : User //the users Tags //the tags itself Tag-relations //stores the tag relations, contains references to document_id and the tag_id Documents // some kind of document such as pdf's or the image from your example, has a relation to a user How would I add tags to documents, while documents belong to a user ? ~Marc
  4. Thank you for your reply! thats where I found: $fields->save($field) so how would you solve the above mentioned thing ? I haven't fount an answer in the API ~Marc
  5. Hello, what is the proper way to save data to the database in PW? Lets say I create a template file which contains a form and I like to save some data to the database while using the PW templates (data templates not visual) with its fields Is the $fields->save($field) meant to be used for such kind of things ? How about more complex thing like the following: Lets say we have the following tables: User //the users Tags //the tags itself Tag-relations //stores the tag relations, contains references to document_id and the tag_id Documents // some kind of document such as pdf's, has a relation to a user How would I add tags to documents, while documents belong to a user ? Cheers Marc
×
×
  • Create New...