brynfld
Forum Replies Created
-
This worked perfectly. Thank you so much for being so attentive to your plugin, I really appreciate the responses.
For reference and for anyone else who winds up here looking for answers.
1. Go to your wordpress installation’s theme directory.
2. Find “single.php” and copy it
3. Paste it into that same directory and rename it “single-staff-member.php”.
4. Open that in your text editor of choice.
5. Remove the default html and php within the “id=content” div element.
6. Create a new set of php tags
7. Within those tags you can customize how you want the page to look. To retrieve the field values you entered for the employee, you can use code like this:$custom = get_post_custom(); $name = get_the_title(); $name_slug = basename(get_permalink()); $title = $custom["_staff_member_title"][0]; $email = $custom["_staff_member_email"][0]; $phone = $custom["_staff_member_phone"][0]; $bio = $custom["_staff_member_bio"][0];
8. With those values you can customize your single user page template like this:
echo "<h2>$name</h2> <br/> <h4>$title</h4>";
Basically I wanted the plugin to provide a page with all staff and for each entry to have it’s own page displaying the information there as well. Is that not possible with the plugin?
I would like to to but unfortunately the site is hosted locally. And I dont have a way to make it public with my current setup.
The loop is currently set to the default.
Im going to paste the html that’s being appended to the page.
<div class="entry-main"> <header class="entry-header"> <div class="entry-thumbnail"><img width="100" height="125" src="https://127.0.0.1/company/wp- content/uploads/2017/10/name_of_employee.jpg" class="attachment-post- thumbnail size-post-thumbnail wp-post-image" alt=""> </div> <h1 class="entry-title">Morley Quatroche, Jr.</h1> </header><!-- .entry-header --> <div class="entry-content"> </div><!-- .entry-content --> <div class="entry-categories">Posted in .</div> </div>
As you can see, the image that does appear is indeed the one that I set as the employee’s image when creating his entry. But the alt text and the class name actually never get appended to the image tag either. Leading me to believe that the creation of the user page is flat out ignoring the loop template. That’s why I don’t think it’s a css issue and I might just be missing some key step to this process. Again sorry I cant post the actual page, I know it would be infinitely more helpful.
- This reply was modified 7 years, 5 months ago by brynfld.
Forum: Fixing WordPress
In reply to: Problem with duplicating paths in Dashboard.Well I figured it out finally and since it seems nobody here was able to lend any assistance I will note how I did it.
Turns out the problem was with IIS. In IIS you can set the bindings for the website. The binding for my site was set to the correct port AND included the domain name in the “Host Name” area. I removed the host name and left the binding pointing at port 80 and viola. My admin Dashboard was reachable again.
If things still seem like they are missing from the Dashboard make sure that the Site Url and Home entries in the wp_options database are set to your site’s url. Including https://
Forum: Fixing WordPress
In reply to: Problem with duplicating paths in Dashboard.Sorry for the bumps but I really need help with this one and can find no other resources.
Forum: Fixing WordPress
In reply to: Problem with duplicating paths in Dashboard.anyone?
Forum: Plugins
In reply to: [Google Drive WP Media] What f-n P12 file?Assuming you figured this out and marked it as resolved but I thought I would post this for anyone else who might have this issue.
You obtain a p12 file by going to the Google Developer Console and creating a project. (I would avoid including a space in the project name, later on you have to link to the p12 file and I think spaces mess up the path.)
Once you do that click “Credentials” on the left under the “API’s & auth” tab. Then click “Create Client ID”. Choose “Service Account” and then click “Create Client ID”. Once you do this your browser should automatically download the p12 file.
Forum: Plugins
In reply to: [Google Drive WP Media] So confused trying to get this working.Thanks Moch. I was misunderstanding the process.
So I got it working finally and I am going to write, in depth, how I figured it out since there does not seem to be a good explanation online for this.
The biggest problem I was having was this: when I first installed the plugin and selected it in the admin panel, I put in the wrong value for “Private Key URL Path” Not realizing that this is the path to the p12 file. After I entered the wrong info I was greeted by a persistent error screen and it would not allow me to re-enter the information.
So first off; You obtain a p12 file by going to the Google Developer Console and creating a project. (I would avoid including a space in the project name, later on you have to link to the p12 file and I think spaces mess up the path.)
Once you do that click “Credentials” on the left under the “API’s & auth” tab. Then click “Create Client ID”. Choose “Service Account” and then click “Create Client ID”. Once you do this your browser should automatically download the p12 file. Now, place the p12 file into a directory within your site install that you know how to navigate to, I placed mine within “plugins”.
One last thing you should do in your Google Developer Console is make sure that you have “Drive API” enabled. To do this go to the API’s section and scroll until you find “Drive API”. Click it and turn it to ON.
Now back to the admin panel on your website. If you are having trouble with the error screen not going away as I mentioned before, we have to go straight to the database (If you click on “Google Drive WP Media” within your admin panel and it IS allowing you to re-enter credentials skip this paragraph). Go to the plugins section of your admin panel. Now deactivate “Google Drive WP Media”. Next, open your database manager of choice (I use phpMyAdmin). First off, back up your database. Although I don’t believe that this process can screw anything up it’s not worth compromising the rest of your site. After that, go to your main site database and find the table named “wp_options”. Click the table and scroll down until you start seeing files that start with “gdwpm”. Select all of of these files and delete them. Now go back to your website and reactivate the plugin.
Now back in the “Google Drive WP Media” section of your admin panel it should be asking you for these things:
Google Email: this is the email account linked to the google drive you are trying to implement. Ex: “[email protected]”
Client ID: Back in your Google Developer Console within your project’s API’s and auth section, you should see in the top right “Client ID”. Copy and paste that into this text-area.
Service Account Name: This is labeled as “Email Adress:” in the API & auth section of your project, right underneath “Client ID”.
Private Key Url Path: Finally this is the path to the p12 file you placed inside your site install. Ex: “https://mywebsite.com/wp-content/plugins/ProjectName-d54566xxxxxx.p12”
Once you do all of this, save the credentials and it should be up and running. If you are greeted by that same error screen (failed to parse p12) odds are you didn’t link your p12 file correctly. If this is the case revise your path to the file and try again. If you get stuck within that error you have to once again go back into the database and delete files as instructed earlier.
Good luck!