• TIDE

    (@tidetraining)


    Trying to either find a plugin or a way to search by the title of a URL.

    Current code:
    [google-drive-embed url=”” title=”” icon=”” newwindow=”yes” style=”normal”]

    The reason for this is I have embedded Google Drive file to my site, trying to make an intranet that links our files from Google Drive.

    The problem is every time I search for these files it shows the page name and not all the files that are linked.

    Is there a way to do this either with custom code or a plugin?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator bcworkz

    (@bcworkz)

    Almost anything is possible with custom coding ?? Are the files you are after only linked through the [google-drive-embed] shortcode? Or are they available elsewhere, such as post meta or attachments?

    The default search will only return WP posts and pages, it doesn’t specifically search for files within. It searches for plain text in order to get related posts and pages only. If the file reference happens to match as plain text, then that’s good, but the search does not see the match as a file per se. If the search is returning the right pages and you merely need to extract the URLs from shortcodes with title=”search-term” attributes, that could be done with a custom search.php template.

    You might try searching for extended search plugins that can do what you want, but I think extracting Google Drive file references might be too specific of a need.

    If you end up needing a custom search.php template, this will supplant the normal search functionality. If you still need that as well, you likely need a custom search form for just file searches.

    Thread Starter TIDE

    (@tidetraining)

    Thanks for the response bcworkz,

    The files are linked through the [google-drive-embed] shortcode for the link to the Google account, The files are then linked using the url=”” of the actual file. Not available as an attachment or post meta.

    I’ll have a look around to see if I can find a plugin to do this, have been looking but so far had no luck.

    The custom coding I think is beyond me for PHP as I do not know this language.

    Moderator bcworkz

    (@bcworkz)

    Good luck in your search. If you continue to have no luck, consider hiring some professional help. If all that’s required is altering the search.php template, it shouldn’t take too much time and thus not be too expensive. A couple possible resources for WP pros are jobs.wordpress.net and jetpack.pro .

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Search by URL title=”Name”’ is closed to new replies.