Car database plugin
-
We are looking for a plugin that can be used by members to add cars they own. I can add a profile field, although this will only work for one car. I am looking for a plugin where a member can add many cars they own, and then the other members can search the list of cars owned by members. Here is an example: A member owns a 1969 Mustang Boss 302. He/she enters that into their profile page. Then they add a 2011 Lexus. Then they add a 2007 BMW 530i. Members can then go to a list page of all cars found in the database and find members that own a specific car. I am speculating there is a plugin that is generic that will do this and can be modified for cars, motorcycles, or just about anything.
Please help,
Wayne Rowlands
-
Hello
Did you find a solution to you car problem, I searching that plugin my self.
I wonderng if i would rewrite the portfolio plugin to match the add members cars.I hope that we can help each other….
volvo_owmer sounds like a plan 😉
I would simply create a custom post type “car” and then add them or in admin backend dashboard as post titles with searchable custom fields as country of origin, year of construction, etc or with gravity forms in frontend. Posts you can after add in every user profile page new tab “My Cars”.
Hello
Thanks for the answer…
I have made a types ” Car ”
And then i add in the function.php :function bp_setup_sub_nav() { global $bp; // Add a nav item for this bp_core_new_nav_item( array( 'name' => __( 'SubNav', 'bp-subnavy' ), 'slug' => 'subnav', 'default_subnav_slug' => 'subnav', 'screen_function' => 'bp_subnav_screen_settings_menu', 'position' => 60 ) ); } add_action( 'bp_setup_nav', 'bp_setup_sub_nav' ); function bp_subnav_screen_settings_menu() { add_action( 'bp_template_content', 'bp_subnav_screen_settings_content' ); bp_core_load_template( apply_filters( 'bp_core_template_plugin', 'members/single/plugins' ) ); } function bp_subnav_screen_settings_content() { echo '<form name="profile" action="" method="post" enctype="multipart/form-data"> <?php wp_nonce_field("update-profile_" . $user_ID) ?> <input type="hidden" name="from" value="profile" /> <input type="hidden" name="action" value="update" /> <input type="hidden" name="checkuser_id" value="<?php echo $user_ID ?>" /> <input type="hidden" name="dashboard_url" value="<?php echo get_option("dashboard_url"); ?>" /> <input type="hidden" name="user_id" id="user_id" value="<?php echo $user_id; ?>" /> <table width="100%" cellspacing="0" cellpadding="0" border="0"> <tr> <td>Bilmärke</td> <td>[types usermeta=”my-select” user_id=”1?]</td> </tr> <tr> <td>Bilmodell</td> <td><input type="text" name="wtf_car-model" id="wtf_car-model" value="" size="30" style="width:97%" /></td> </tr> <tr> <td>Årsmodell</td> <td><input type="text" id="wpcf-arsmodell" name="wpcf_arsmodell" value="" size="30" style="width:97%" /></td> </tr> <tr> <td>Effekt / Vridmoment</td> <td><input type="text" name="wtf_effekt-vrid" id="wtf_effekt-vrid" value="" size="30" style="width:97%" /></td> </tr> <tr> <td>Motor, växellåda och avgassystem</td> <td><textarea class="theEditor" name="wtf_car-engine" id="wtf_car-engine" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td>Effekt och prestanda </td> <td><textarea class="theEditor" name="wtf_car-effect" id="wtf_car-effect" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td>Chassi</td> <td><textarea id="wpcf-textarea-chassi" name="wpcf_chassi" rows="5" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td>Fälgar, däck och bromsar</td> <td><textarea class="theEditor" name="wtf_car-tire" id="wtf_car-tire" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td>Interiör / Inredning</td> <td><textarea class="theEditor" name="wtf_car-interior" id="wtf_car-interior" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td>Bilstereo och multimedia</td> <td><textarea class="theEditor" name="wtf_car-stereo" id="wtf_car-stereo" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td>Exteriör / Styling/td> <td><textarea class="theEditor" name="wtf_car-styling" id="wtf_car-styling" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td>Framtidsplaner</td> <td><textarea class="theEditor" name="wtf_car-planer" id="wtf_car-planer" cols="60" rows="4" style="width:97%"></textarea></td> </tr> <tr> <td align="center" colspan="2"><input type="submit" value="Update" /></td> </tr> </table> <input type="hidden" name="action" value="update" /> </form>'; }
But i dont now how i can the information from the dashboard car:
Becouse there i can add manual cars…But i whant that the users can add cars.
add_filter('manage_edit-cars_columns', 'add_new_cars_columns'); function add_new_cars_columns($listings_columns) { $new_columns['cb'] = '<input type="checkbox" />'; $new_columns['title'] = _x('Car name', 'column name'); $new_columns['author'] = __('Owner'); $new_columns['thumbnail'] = __('Thumbnail'); $new_columns['make'] = __('Make'); $new_columns['date'] = _x('Date', 'column name'); $new_columns['ratings'] = __('Ratings'); return $new_columns; } add_action('manage_cars_posts_custom_column', 'manage_cars_columns', 10, 2); function manage_cars_columns($column_name, $id) { global $post; switch ($column_name) { case 'id': echo $id; break; case 'thumbnail': echo get_the_post_thumbnail( $post->ID, 'car_poster' ); break; case 'make': $post_type = get_post_type($post_id); $terms = get_the_terms($post_id, 'make'); if ( !empty($terms) ) { foreach ( $terms as $term ) $post_terms[] = "<a href='edit.php?post_type=cars&make={$term->slug}'> " . esc_html(sanitize_term_field('name', $term->name, $term->term_id, $taxonomy, 'edit')) . "</a>"; echo join( ', ', $post_terms ); } else echo '<i>No terms.</i>'; break; case 'condition': $post_type = get_post_type($post_id); $terms = get_the_terms($post_id, 'condition'); if ( !empty($terms) ) { foreach ( $terms as $term ) $post_terms[] = "<a href='edit.php?post_type=cars&condition={$term->slug}'> " . esc_html(sanitize_term_field('name', $term->name, $term->term_id, $taxonomy, 'edit')) . "</a>"; echo join( ', ', $post_terms ); } else echo '<i>No terms.</i>'; break; default: break; } // end switch } ?>
This code looks very interesting and it is exactly what I meant , but I use gravity forms everywhere what is easy to set and unfortunately I am not a PHP expert, so I can’t help you with your problem. But I will watch this thread , I want to see a final working solution.
hello
I´m not finish yet, but I have also figured out to add top menu and under sub.
I have one top and 3 sub menu..And i can see a page that i have in my theme…
now i need to manage to add the info… 😐
i dont whant to show the script but i can show a image
Now i have menage to rewrite a plugin to match the users demands…
They can add cars, image, info… 🙂Now i only nedd to add the select box for the brands…
and the link the the page that show all the info….I have manage to rewrite a plugin, but I´m wondering one thing…
I have create the db to wp_cars
but when i connect to the db all i se is blank page:
function cars_get_total_posted($user_id=false){ if(!$user_id) $user_id=bp_displayed_user_id (); //Needs revisist global $wpdb; $count=$wpdb->get_var($wpdb->prepare("SELECT count('*') FROM {$wpdb->cars} WHERE post_author=%d AND post_type=%s AND (post_status='publish'||post_status='draft')",$user_id, cars_get_posttype())); return intval( $count); }
Hope someone can help me.
Would be cool to see if you get anywhere with this plugin.
Since im looking for the exact same thing! =)Get back to me please =)
- The topic ‘Car database plugin’ is closed to new replies.