hook / filter help

This topic contains 6 replies, has 4 voices, and was last updated by  Stiofan O’Connor 7 years, 5 months ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #307976

    Christoph
    Expired Member
    Post count: 30

    Hey gd-team,
    I’m looking for a filter or hook to modify a custom field on the first submit of the place and also on all updates.
    Could you please help which is the right one to go with?

    BR
    Christoph

    #308069

    Kor
    Moderator
    Post count: 16516

    Hi Christoph,

    Could you be more specific about what you’re trying to change here? Perhaps a link and some screenshots?

    Thanks!

    #308089

    Christoph
    Expired Member
    Post count: 30

    Hi Kor,
    thanks for swift feedback. Sure. Here we go.
    I have a hidden field in the form that shall be used for a QR code.
    This QR code will be generated automatically from the address and telephone fields entered.
    See 1.jpg (field icon called here)

    Now, just after pressing the review your listing button (2.jpg) I want to generate this QR code on the fly.
    So it must be available before the review screen shown in 3.jpg.

    Also the same must be executed if a user is updating the listing itself.

    Best regards
    Christoph

    #308432

    Paolo
    Site Admin
    Post count: 31206

    Hi Christoph,

    I asked to the developers to read your question and provide an answer. They should have enough details to provide a solution.

    They’ll let us know asap.

    Thanks

    #308601

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    You can simply manipulate the $_REQUEST data before it’s proccesed

    
    
    add_action('geodir_detail_before_main_content', '_my_geodir_action_geodir_set_preview_post', 7);
    function _my_geodir_action_geodir_set_preview_post(){
    global $post, $preview, $gd_session;
        $is_backend_preview = (is_single() && !empty($_REQUEST['post_type']) && !empty($_REQUEST['preview']) && !empty($_REQUEST['p'])) && is_super_admin() ? true : false; // skip if preview from backend
        if (!$preview || $is_backend_preview) {
            return;
        }// bail if not previewing
    
    //lets check what info we have
    print_r($_REQUEST);
    
    }

    Stiofan

    #308702

    Christoph
    Expired Member
    Post count: 30

    Hi guys (Kor, Paolo, Stiofan)!
    You’re simply great. Thanks for high class support!
    It’s working fine. Really great plugin in people behind.
    Can be set to resolved.

    BR
    Christoph

    #309058

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    🙂

Viewing 7 posts - 1 through 7 (of 7 total)

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket