Support Forum » User Profile

Forum Replies Created

Viewing 15 posts - 1 through 15 (of 26 total)
  • Author
    Posts
  • in reply to: Relationships Post Query Not Fetching #45080
    davidrknowlesdavidrknowles
    Participant

    The above error goes away if I specify a "to" in the query, but this doesnt work well if I am using a slug and not an ID, as I dont think ID is availible in the loop yet.

    This also doesnt solve the problem of it returning nothing and the theme replacing it with the archive layout.

    $query->set( 'relationship', [	
    	'id'    => 'client_projects',
    	'from' 	=> 178,
    	'to'    => 107
    ]);
    in reply to: Relationships Post Query Not Fetching #45079
    davidrknowlesdavidrknowles
    Participant

    Just running through the debug, I get the following database error:

    WordPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ')) WHERE 1=1 AND wp_posts.post_name = 'scott-street' AND wp_posts.post_t...' at line 2]

    SELECT wp_posts.* , mbr.to FROM wp_posts INNER JOIN wp_mb_relationships AS mbr ON (mbr.from = wp_posts.ID AND mbr.type = 'client_projects' AND mbr.to IN ()) WHERE 1=1 AND wp_posts.post_name = 'scott-street' AND wp_posts.post_type = 'project' GROUP BY mbr.to, wp_posts.ID ORDER BY mbr.order_to

    in reply to: image-select error #22021
    davidrknowlesdavidrknowles
    Participant

    The metabox looks like this:

    ?php
    
    add_filter( 'rwmb_meta_boxes', 'your_prefix_register_meta_boxes' );
    
    function your_prefix_register_meta_boxes( $meta_boxes ) {
        $prefix = '';
    
        $meta_boxes[] = [
            'title'      => esc_html__( 'drk-content', 'text-domain' ),
            'id'         => 'drk-content',
            'post_types' => ['post'],
            'context'    => 'side',
            'priority'   => 'high',
            'fields'     => [
                [
                    'id'       => $prefix . 'thumb-image',
                    'type'     => 'image_select',
                    'name'     => esc_html__( 'Thumb Image', 'text-domain' ),
                    'desc'     => esc_html__( 'Thumb image for grid feature', 'text-domain' ),
                    'required' => 1,
                ],
            ],
        ];
    
        return $meta_boxes;
    }
    in reply to: Submission from non-logged in users failing, #21970
    davidrknowlesdavidrknowles
    Participant

    Fixed that too lol turns out I was editing the shortcode in the WP Block and not the beaver builder module.

    Seems to be working perfectly now. thanks

    in reply to: Submission from non-logged in users failing, #21969
    davidrknowlesdavidrknowles
    Participant

    Ok I think I have sorted it, being away from WP for a while has made forget what a hassle caching can be, I turned off VARNISH in my server and it seems to be all work.

    The only weird thing now is the Title field is now showing regardless of not having it in the shortcode.

    in reply to: Submission from non-logged in users failing, #21968
    davidrknowlesdavidrknowles
    Participant

    I really dont understand why it's not working, I have updated to PHP 7.4, I have reflushed the server permissions, restarted the server. Now its not submitting with all the plugins off and the default theme without being logged in.

    in reply to: Submission from non-logged in users failing, #21963
    davidrknowlesdavidrknowles
    Participant

    Thats really weird both those links work fine.

    This is my form: https://davidrknowles.com/contact/

    in reply to: Submission from non-logged in users failing, #21952
    davidrknowlesdavidrknowles
    Participant

    Also worth adding without both ajax request or reCaptcha it still fails in a different browser like Brave or firefox, it just gives a 404.

    in reply to: Submission from non-logged in users failing, #21951
    davidrknowlesdavidrknowles
    Participant

    Hi Long,

    I tried all of what you have suggested and it is as follows.

    Everything off apart from meta box and meta box AIO:
    with ajax = Fail
    without ajax = Pass

    So I turned everything on again:
    with ajax = Fail
    without ajax = Pass

    I then tried with without ajax but added in reCaptcha = Fail

    So it looks like its to do with the validation of the ajax request or reCaptcha, maybe requiring some kind of user validation.

    Hope this helps

    in reply to: Submission from non-logged in users failing, #21945
    davidrknowlesdavidrknowles
    Participant

    Ignore the PHP Warning: chmod() warning, it was just a server permission error, was hoping it would fix the form submission issue but to no avail.

    I have tried removing the action rwmb_frontend_after_process and also editing the post type settings, and removing reCaptcha and AJAX. without AJAX I get a 404 returned.

    in reply to: MB Admin Columns - not sortable when using customtable #12124
    davidrknowlesdavidrknowles
    Participant

    Cool, thought I was going crazy lol

    in reply to: Taxonomy Field - Not saving to term_relationships #11434
    davidrknowlesdavidrknowles
    Participant

    Thanks Anh, thought this might have been the case, I have made an AJAX hack but am just trying to refine it a little and use a filter or action that passes the meta fields before it is saved to the database.

    in reply to: Taxonomy Field - Not saving to term_relationships #11406
    davidrknowlesdavidrknowles
    Participant

    Just released I didn't finish what I was thinking lol

    So the taxonomy field is not creating a relationship with the post and the term, I think the standard way is to write the link in the term_relationships table but this isn't happening, instead, it is writing to the custom table I have on that post type for all the meta.

    I am yet to try and see if having the table is the cause of the issue.

    in reply to: Limit form submission to once per user #11200
    davidrknowlesdavidrknowles
    Participant

    Yes you could do this by using some of the hooks, to check the author of previously entered forms and maybe a redirect if one has already submitted a form. You then would need to set the user role caps for the custom post type so the user can only edit own. You could create a filter on the archive query that only retrieves post from that user too.

    As far as GF integration, its my understanding that this is the point of frontend submission and with the rest of the metabox conditional extensions you could do most of what gravity does. Only thing you may need is a notification system for email notifications.

    in reply to: submit form with ajax #10481
    davidrknowlesdavidrknowles
    Participant

    +1 for sure

Viewing 15 posts - 1 through 15 (of 26 total)