Support Forum » User Profile

Forum Replies Created

Viewing 7 posts - 31 through 37 (of 37 total)
  • Author
    Posts
  • in reply to: Fields Not Showing in Views -- or Frontend #28680
    zenjukai@gmail.com[email protected]
    Participant

    Hey Long,

    Yes post type plural name is "Animals", the slug, which is autogenerated from the "Singular Name" is "animal". I also tried to change the slug so that it is plural as well, but did not work.

    So after some digging (and maybe this should be put into your documentation) is that when you are adding that page/archive to your menu, you cannot add it from your "Pages" section, but rather from the post type section. You have to click on that post type, then "View All", then you have the Animal Archives which then shows the correct information.

    So all is working but again this should not be so hard. Maybe consider updating your documentation with some clear understanding.

    Cheers

    in reply to: SVG with Image Advanced Custom Field #28470
    zenjukai@gmail.com[email protected]
    Participant

    Hey Long,

    Thank you ... yes, I also came to that conclusion this morning after doing some Googling. I did find that the solution above that I mentioned is the best option in this case.

    {% for item in post.icon %}
    <img src="{{ item.full.url }}" width="42" height="42" alt="{{ item.full.alt }}">
    {% endfor %}

    Thanks again for your time.

    Cheers

    in reply to: Location Bug, Error, Or? #28464
    zenjukai@gmail.com[email protected]
    Participant

    Hey Long,

    LOL, ok ... silly me, that was an easy fix. =)

    Cheers

    in reply to: SVG with Image Advanced Custom Field #28434
    zenjukai@gmail.com[email protected]
    Participant

    Hello Long,

    Thank you, I did try that already. What I am seeing happening is, the SVG is 120x120, but when it outputs that file it is given the height and width of "0" -- therefore you cannot see the SVG.

    Here is a video showing what happens: https://youtu.be/t2CYNcb5lto

    Also, I tried this after the video and it works. I can do that, but I am wondering why the code snippet is not outputting or at least an option to apply a custom width/height.

    Original Twig snippet

    {% for item in post.icon %}
    <img src="{{ item.full.url }}" width="{{ item.full.width }}" height="{{ item.full.height }}" alt="{{ item.full.alt }}">
    {% endfor %}

    Work Around snippet

    {% for item in post.icon %}
    <img src="{{ item.full.url }}" width="42" height="42" alt="{{ item.full.alt }}">
    {% endfor %}

    Any thoughts?

    Cheers

    in reply to: dateFormat #27811
    zenjukai@gmail.com[email protected]
    Participant

    Hey Long,

    Me again ... so never mind with the issue above. What I am seeing is the error is not coming from me or the plugin, but rather how Oxygen renders the custom variables. Yes it can probably work somehow, but it seems kind of pointless to make a hack for a simple process.

    I love metabox ... it is an amazing plugin that makes life so much easier, so to just hack it for a simple function doesn't make sense.

    So I am just going to move away from Oxygen and just use Views with Twig! =)

    Cheers and thanks again for your time and effort.

    in reply to: dateFormat #27810
    zenjukai@gmail.com[email protected]
    Participant

    Also Long, just as an FYI. I have tried the same output on a theme based site that used "Views" instead on injecting the code and all works great.

    So I am wondering if it has to do with the setup or the execution with Oxygen?

    Cheers

    in reply to: dateFormat #27807
    zenjukai@gmail.com[email protected]
    Participant

    Hello Long,

    Thank you for your reply. Here is the generated PHP code. I am using Oxygen and Script Organizer, so I took the generated code and then created a script to run, as I don't have a functions.php file. The format still doesn't change. Any thought?

    <?php
    add_filter( 'rwmb_meta_boxes', 'rswp_oxygen_dateFormat_events' );
    
    function rswp_oxygen_dateFormat_events( $meta_boxes ) {
        $prefix = '';
    
        $meta_boxes[] = [
            'title'      => __( 'Event Details', 'rswp_oxygen' ),
            'id'         => 'event-details',
            'post_types' => ['event'],
            'context'    => 'after_title',
            'fields'     => [
                [
                    'name'       => __( 'Event Details', 'rswp_oxygen' ),
                    'id'         => $prefix . 'event_details',
                    'type'       => 'textarea',
                    'rows'       => 6,
                    'required'   => 1,
                    'save_field' => 1,
                ],
                [
                    'name'       => __( 'Event Date', 'rswp_oxygen' ),
                    'id'         => $prefix . 'event_date',
                    'type'       => 'date',
                    'required'   => 1,
                    'js_options' => [
                        'dateFormat' => 'd-MM-yy',
                    ],
                    'save_field' => 1,
                ],
                [
                    'name'       => __( 'Event Time', 'rswp_oxygen' ),
                    'id'         => $prefix . 'event_time',
                    'type'       => 'time',
                    'required'   => 1,
                    'save_field' => 1,
                ],
                [
                    'name'       => __( 'Event Location', 'rswp_oxygen' ),
                    'id'         => $prefix . 'event_location',
                    'type'       => 'textarea',
                    'required'   => 1,
                    'save_field' => 1,
                ],
            ],
        ];
    
        return $meta_boxes;
    }

    Sorry, I am new at this, so still a bit of a learning curve. Thanks again for your help.

    Cheers

Viewing 7 posts - 31 through 37 (of 37 total)