WP Manifestindependent plugin directory
manifest / integrations / wp-simple-quote-generator

Simple Quote Generator

Lightweight WordPress plugin that displays random inspirational quotes via shortcode.

by Your Name · github.com/yudtie/wp-simple-quote-generator · website

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/yudtie/wp-simple-quote-generator/archive/refs/heads/main.zip

A lightweight WordPress plugin that displays random inspirational quotes from quotable.io with smooth AJAX-powered quote generation.

Features

  • Random Quotes: Fetches quotes from quotable.io API
  • Fallback System: Built-in quote collection ensures the plugin always works, even offline
  • AJAX Updates: Get new quotes without page reload
  • Customizable: Choose colors for text and buttons
  • Responsive Design: Works beautifully on all devices
  • Easy to Use: Simple shortcode integration
  • Secure: Built with WordPress security best practices
  • Smart SSL Handling: Automatically detects local vs production environments

Installation

  1. Upload the quote-generator folder to /wp-content/plugins/
  2. Activate the plugin through the 'Plugins' menu in WordPress
  3. Go to Settings → Quote Generator to customize appearance
  4. Add the shortcode [quote_generator] to any page or post

Usage

Display Quotes

Simply add this shortcode to any page, post, or widget:

[quote_generator]

Customize Appearance

Navigate to Settings → Quote Generator in your WordPress admin panel to customize:

  • Quote Text Color - Color for the quote text
  • Author Text Color - Color for the author name
  • Button Text - Customize the button label (default: "Get New Quote")
  • Button Background Color - Button background color
  • Button Text Color - Button text color

How It Works

  1. The plugin fetches a random quote from quotable.io when the page loads
  2. Users can click the button to get a new quote via AJAX (no page refresh needed)
  3. The quote smoothly fades in with author attribution
  4. All styling can be customized through the admin settings

Requirements

  • WordPress 5.0 or higher
  • PHP 7.4 or higher
  • Active internet connection (to fetch quotes from API)

Browser Support

  • Chrome (latest 2 versions)
  • Firefox (latest 2 versions)
  • Safari (latest 2 versions)
  • Edge (latest 2 versions)
  • Mobile browsers (iOS Safari, Chrome Mobile)

Frequently Asked Questions

Can I use my own quotes instead of the API?

The current version fetches quotes from quotable.io. Future versions may include the ability to add custom quotes.

What happens if the API is down?

The plugin automatically uses a built-in collection of 20 inspirational quotes as a fallback. Your visitors will always see a quote, even if the API is unavailable or there are SSL certificate issues.

Can I display multiple quote boxes on one page?

Currently, it's recommended to use one shortcode per page. Multiple instances may work but are not officially supported.

Can I customize the styling beyond colors?

You can add custom CSS to your theme to further customize the appearance. The main container uses the class .qg-container.

Is the plugin translation-ready?

Yes, the plugin uses WordPress translation functions and has the text domain quote-generator.

Developers

File Structure

quote-generator/
├── quote-generator.php                       # Main plugin file
├── includes/
│   ├── class-quote-generator-admin.php       # Admin settings
│   └── class-quote-generator-shortcode.php   # Shortcode handler
├── assets/
│   ├── js/
│   │   └── quote-generator.js                # Frontend JavaScript
│   └── css/
│       └── quote-generator.css               # Frontend styles
├── PLAN.md                                   # Development documentation
└── README.md                                 # This file

Hooks & Filters

The plugin currently doesn't expose custom hooks, but this may be added in future versions.

API Reference

External API: https://api.quotable.io/random

Response Format:

{
  "content": "Quote text here",
  "author": "Author Name",
  "tags": ["tag1", "tag2"],
  "length": 42
}

Changelog

1.0.0 (2026-01-08)

  • Initial release
  • Quote display via shortcode
  • AJAX quote generation
  • Admin customization settings
  • quotable.io API integration

License

GPL v2 or later

Support

For bug reports or feature requests, please create an issue on the GitHub repository.

Credits

  • Quotes provided by quotable.io
  • Developed with WordPress coding standards
  • Built with security and performance in mind

Enjoy inspiring your visitors with random quotes!