• Hello,

    I have a blog of tractors specifications and prices. I want to make a page where user can select two or three models from drop-down list and click on comparison. Is there any way to comapre tables having specs and price?

    Example page: https://www.tractordata.com/compare/

    I want to make a similar page on my wordpress site.

    Please help.
    Shall be very thankful.

    • This topic was modified 5 years, 4 months ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not a Developing with WordPress topic. And deleted short link
Viewing 5 replies - 1 through 5 (of 5 total)
  • Moderator bcworkz

    (@bcworkz)

    If it can be done with PHP, there will always be a way. I would start with a custom page template that the selection form submits to. The submitted data will have adequate data for page template code to query for specific models and related data.

    The specifics depend on how the data is stored and in what form the query results are returned in. Because HTML tables are organized by rows, the usual WP loop through query results doesn’t work well. Either forgo the table for the CSS box model so ordering can be swapped between column and row, or run a nested loop to generate the table. The outer loop is the list of attributes being compared, the inner is an index into query results. This is assuming the results would be organized similar to the selection fields, models along the X-axis and attributes down the Y-axis.

    Thread Starter kaisar10

    (@kaisar10)

    Is there wordpress plugin available to do so?

    Thank you.

    Moderator bcworkz

    (@bcworkz)

    One would think so, right? I’m unaware of one myself. Your search skills are likely as good as mine. Because such a function is strongly related to how the data is stored, it could be difficult to find something to work with your data. Your data may need to be transformed to work with the plugin. There is a fair possibility of such a plugin that is an extension of WooCommerce since its product data format is already well established. If you otherwise do not need WooCommerce, I’m doubtful it’s worth using just to get a comparison table.

    Hopefully someone else here can suggest something.

    Thread Starter kaisar10

    (@kaisar10)

    Thank you @bcworkz

    Your suggestion of a comparison table is good. But I have to make it manually for all models, I want a drop-down list of models so that user can select the model and click on the comparison button then in result it must show the table. I can make the tables for all. But I need the functionality for user selection.

    Can you please suggest to any expert?

    Moderator bcworkz

    (@bcworkz)

    No specific suggestions, but you can find someone through https://jobs.wordpress.net/ or https://jetpack.pro/. Do not accept any unsolicited offers of paid assistance resulting from this topic though. Sadly, members have been contacted off-forum in the past by random strangers offering their “services”. While it could be a legitimate offer, you cannot be sure. Making unsolicited offers is an unprofessional practice which brings their veracity into question.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘How to make a posts comparison page on non woocommerce website?’ is closed to new replies.