• Resolved gmex1292

    (@gmex1292)


    I was using version 1.7.8.11 and upgraded to the latest version 1.9.4.4. After updating the code to read the picture and link fields stopped working like before.

    I am reading a picture (Image Upload Field) and link field (Link Field), and before it would pull in the picture as a hyperlink and now it’s only the string. The link field also.

    For each I was using this and it worked fine (added your suggestion from other post):

    
    		  if ( $this->field->name() == 'my_page_url' ) {
    		  $myPageURL = $this->field->get_value();
    		  }
    		  if ( $this->field->name() == 'picture' ) {
    		  $myPicture= $this->field->get_value();
    		  } 

    Each of these just returns a string. Picture just the file name, and the link field just the display text.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author xnau webdesign

    (@xnau)

    This was changed a while back, these methods return a bare value now. Try using this method to get your full display HTML:

    $this->field->get_value_display()

    Thread Starter gmex1292

    (@gmex1292)

    This worked! Thank you so much!!!

    Thread Starter gmex1292

    (@gmex1292)

    I just wanted to add that I really appreciate the support that you provide! Great plugin!

    ferbit

    (@ferbit)

    Same thing is happening with my client. Every time I try to update their PD plugin, the results are bare. It’s obvious a recordset is available because it is looping through the array, but not displaying any values. It’s for available apartment units. Any help would be greatly appreciated.

    <?php 
    if(isset($_GET['units'])){
      $records = json_decode(json_encode($this->records), True);
      $nr = array();
      foreach($records as $record){
    		$nr[] = array_column($record, 'value', 'name');
      }
      echo json_encode($nr);
      die;
    }
    
    ?>
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Link nd Picture fields not working after update’ is closed to new replies.