Jump to content

Search the Community

Showing results for tags 'id'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Welcome to ProcessWire
    • News & Announcements
    • Showcase
    • Wishlist & Roadmap
  • Community Support
    • Getting Started
    • Tutorials
    • FAQs
    • General Support
    • API & Templates
    • Modules/Plugins
    • Themes and Profiles
    • Multi-Language Support
    • Security
    • Jobs
  • Off Topic
    • Pub
    • Dev Talk

Product Groups

  • Form Builder
  • ProFields
  • ProCache
  • ProMailer
  • Login Register Pro
  • ProDrafts
  • ListerPro
  • ProDevTools
  • Likes
  • Custom Development

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start





Website URL







Found 4 results

  1. Currently, I have a page set up listing all child pages using a foreach loop and outputting some information (thus far, it is all gravy). However, I ran into a slight problem. I have a "button" on each item being rendered that when clicked needs to send the page id to another page for processing via ajax. I thought I could just save the item id like : <?php $itemId = $item->id; ?> And then encoding it below in my javascript: var itemId = <?php echo json_encode($itemId); ?>; var data = { itemId: itemId, }; $.ajax({ type: "POST", url: "/intra/status/", data: data, success: function(){ console.log(itemId); } }); However, it is only posting the last page's id rendered by the foreach. Have I just overlooked something simple on this?
  2. Hello, On my website I want to import categories from another website based on prestashop. For each categorie a new child page will be created, but if I want to import the categories again because there were some changes made in the categories in Prestashop, then the page has to be updated and not create a new page. So I tried the following: $parent = $this->session->Parent; foreach($categories as $item) { //make sure end of string ends with alphanumeric $str_catlink = $item['link_rewrite']; $category_name = preg_replace('/[^a-z0-9]+\Z/i', '', $str_catlink); // see if we already have this item $page = $parent->child("name=($category_name)"); // if we don't have this item already then create it if(!$page->id) { $page = new Page(); //etc etc etc But if I want to import the same categories now, there is an error: Call to a member function child() on a non-object. How can this be solved? Does anyone have an idea?
  3. Hello! My first post on the forum and I start with a question. I'm trying to modify the module datatable by Soma and I want to search by $page->id. code: if( $this->input->get->sSearch ) { $q = $this->sanitizer->text($this->input->get->sSearch); $selector .= "title|body%=$q,"; } my code (doesn´t work): if( $this->input->get->sSearch ) { $q = $this->sanitizer->text($this->input->get->sSearch); $selector .= "id|title|body%=$q,"; } $thanks->ryan; $thanks->soma; And please excuse my bad English
  4. Are images that are uploaded to a page assigned a unique id number?
  • Create New...