Results 1 to 2 of 2

Thread: News extended module template overriding

  1. #1
    New user
    Join Date
    09-13-17.
    Posts
    26

    Default News extended module template overriding

    Hi, I need to extend tl_news extension. I added some fields (e.g.: fileTree, select with related news options etc.). The entries successfully saved in database. And got the templatevars in the news list template. The image stored in the DB with blob format and related news is serialized array. How can I manipulate this data before displaying in the template file? I am also using news_categories module. If I extend the news module, is this affecting the news category filtering?

  2. #2
    User Andreas's Avatar
    Join Date
    07-11-09.
    Location
    Mönchengladbach
    Posts
    499

    Default

    I guess you're talking about the core newsletter - this is not an extension.

    Image:
    If you've done all right, then your image field contains a UUID representing a file in tl_files. You can get its values like this
    PHP Code:
    dump(\FilesModel::findByUuid($myFileUuid));
    dump(\FilesModel::findByUuid($myFileUuid)->path);
    dump(\FilesModel::findByUuid($myFileUuid)->meta); 
    Serialized array:
    PHP Code:
    dump(deserialize($mySerializedArray)); 
    News category:
    No, I don't think so.
    Web-Development, Freelancer, Burgtech, XHTML, HTML5, CSS, PHP, Javascript, MooTools, MySQL and more
    Amazon wishlist

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •