Plugin Directory

Changeset 3240633


Ignore:
Timestamp:
02/14/2025 01:16:02 PM (12 months ago)
Author:
ircf
Message:

1.38 : added pdo/xml php extension check, concatenate meta values when multiple fields are mapped

Location:
feed2post-ircf/trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • feed2post-ircf/trunk/README.txt

    r3240200 r3240633  
    120120== Changelog ==
    121121
     122= 1.38 =
     123PDO/XML : Added error when missing PHP extension.
     124Concatenate meta values when multiple field are mapped.
     125
    122126= 1.37 =
    123127Added missing post and user fields.
  • feed2post-ircf/trunk/feed2post.php

    r3240200 r3240633  
    44 * Plugin URI: https://ircf.fr
    55 * Description: Import CSV, XLS, XML, RSS, JSON, SQL, Open AI Chat GPT, Google Reviews, Facebook, LinkedIn, AC3, SIRTAQUI and many more feed types
    6  * Version: 1.37
     6 * Version: 1.38
    77 * Author: IRCF
    88 * Author URI: https://ircf.fr/
  • feed2post-ircf/trunk/includes/feed/feed2post-pdo.php

    r3240200 r3240633  
    5050  function update_fields($reset = false){
    5151    $fields = parent::update_fields($reset);
     52    if (!class_exists('PDO')) throw new Exception(sprintf(__('PHP %s extension is not installed', 'feed2post'), 'PDO'));
    5253    $pdo = new PDO($this->dsn, $this->username, $this->password); // TODO , $this->options);
    5354    $stmt = $pdo->query($this->query);
  • feed2post-ircf/trunk/includes/feed/feed2post-xml.php

    r3211088 r3240633  
    8282  protected function load_xml(){
    8383    $xml = $this->http_query();
     84    if (!class_exists('DOMDocument')) throw new Exception(sprintf(__('PHP %s extension is not installed', 'feed2post'), 'DOM'));
    8485    $dom = new DOMDocument();
    8586    $dom->loadXML($xml);
  • feed2post-ircf/trunk/includes/feed2post-feed.php

    r3240200 r3240633  
    347347          // meta field
    348348          $meta_name = feed2post_post_field_name($field);
    349           $post['meta_input'][$meta_name] = $this->get_field_value($name, $result, true);
     349          if (!isset($post['meta_input'][$meta_name])) $post['meta_input'][$meta_name] = '';
     350          $post['meta_input'][$meta_name] .= $this->get_field_value($name, $result, true);
    350351        }
    351352      }
Note: See TracChangeset for help on using the changeset viewer.