• Resolved manoscham

    (@manoscham)


    Hello I want in the step 3, the option premium package to be preselect for the user (not quantity) just to be only preselect ( this option calculate a standar price* days of rental) when I try to modify the php file I am getting 403 access denied. What should I do?

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author e4jvikwp

    (@e4jvikwp)

    Hello,

    Thanks for your message. We suggest getting in touch with our team through our website for questions related to the Pro/commercial version of the plugin. Options/extra services are not available in the free version of the plugin, and so in order to not go off-topic on this forum, we suggest getting in touch with us through our website or by opening a support ticket. Thank you!

    The error with code 403 (Forbidden) is probably caused by a third-party plugin, or by some security rules in place on your server. That error message has got nothing to do with VikRentCar, it’s usually a firewall rule or a security plugin that intercepts requests containing PHP code.

    Also, Options/Extras can be configured as “mandatory”, by turning on the parameter “Always selected”. You may not need to modify the PHP code, and if you needed to do so, then editing a PHP core file is strongly discouraged, or you will lose your changes by installing the next official plugin update. It would be even worse if you decided to keep an old version for a customization that was not done properly. In fact, the step #3 of the booking process is a “View” (page) that can be overridden. Thanks to the overrides technique, you will be able to work on a cloned copy of the original template file of a specific “View” of the plugin.
    Overrides can be created manually by following the technical documentation on our website, or you can just use the “Overrides Manager” tool available in the Configuration page of VikRentCar.

    This way you will not apply any changes to core files, and you will always be able to install future updates without losing your customization.

    We hope this helps!

    The VikWP Team

    Thread Starter manoscham

    (@manoscham)

    Fyi i have the pro version. 403 caused from my firewall settings you were right. Thats i want to change is the option to be selected but not mandatory, user can unselected if needed, but when enters the step 3 for marketing reasons I want to be already selected(checked). I make a change in the showprc default.php file via the in the input to be checked in the VikRentCar – Page Override but nothing happened.

    OLD
    $optquaninp = “<input type=\”checkbox\” name=\”optid”.$o[‘id’].”\” value=\”1\”/>”;

    New
    $optquaninp = “<input type=\”checkbox\” name=\”optid”.$o[‘id’].”\” value=\”1\” checked=\”checked\”/>”;

    Thread Starter manoscham

    (@manoscham)

    Also for some reason even with changes or reverted to the old php file the icon now is red.
    https://jumpshare.com/s/zyEBNlp82wKiLuUMN3Q0

    Plugin Author e4jvikwp

    (@e4jvikwp)

    Hello,

    Thanks for sharing the details. We are glad to see you’re using the “Overrides Manager” tool so that you are actually working on a non-core file, but rather on a copy of the default template for the View (page) that shows the options/extra services during the booking process.

    What we can tell you is that the “red icon” in the Overrides Manager means that your override is disabled (inactive). By clicking the gear icon next to the file path at the top of the main editor window, you will be able to activate the override again. You need to select that file with the red icon first. The file-icon needs to be green for the override to be active.

    Also, we confirm you’re working on the correct file and adding the checked="checked" attribute to the input tag is the right solution. We understand you don’t want the options to be mandatory, but rather selected by default.

    Just make sure your override is active, and you can add some additional code to make sure your override is working, even something like echo 'we are here'; will help you understand what portion of code you’re working on.

    We hope this helps!

    The VikWP Team

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.