Changeset 2789063
- Timestamp:
- 09/23/2022 01:49:16 AM (3 years ago)
- Location:
- uqrate
- Files:
-
- 5 added
- 10 edited
-
assets/banner-1554x500.png (modified) (previous)
-
assets/banner-772x250.png (modified) (previous)
-
assets/screenshot-3.png (modified) (previous)
-
assets/screenshot-4.png (added)
-
assets/screenshot-5.png (added)
-
assets/screenshot-6.png (added)
-
assets/screenshot-7.png (added)
-
assets/screenshot-8.png (added)
-
trunk/class.admin.php (modified) (1 diff)
-
trunk/class.core.php (modified) (3 diffs)
-
trunk/class.sync.php (modified) (1 diff)
-
trunk/readme.txt (modified) (3 diffs)
-
trunk/uqrate.php (modified) (1 diff)
-
trunk/views/admin.php (modified) (7 diffs)
-
trunk/views/css/a.settings.css (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
uqrate/trunk/class.admin.php
r2786655 r2789063 26 26 public static function admin_init() { 27 27 if ( ! is_admin() ) return; 28 /*****************************************************************29 * Register the custom plugin-settings page (HTML FORM),30 * as a Settings-submenu page, and store in DB upon user SUBMIT.31 ****************************************************************/32 28 self::settings_register(); 33 29 self::remove_native_comments(); 34 return;35 //... nothing below is needed lest redirect on activation desired.36 if ( get_option( self::cfg('wp_opts_flag_jt') ) )37 return;38 if ( self::create_posts_threads_jt() ) {39 if ( get_option( self::cfg('wp_opts_flag_active') ) )40 return;41 delete_option( self::cfg('wp_opts_flag_active') );42 if ( headers_sent() ) return;43 false && wp_redirect(44 add_query_arg(45 [ 'page' => self::SETUP_PAGE ],46 admin_url( 'options-general.php' )47 )48 );49 }50 30 } 51 31 public static function admin_menu() { -
uqrate/trunk/class.core.php
r2786655 r2789063 204 204 } 205 205 public static function preObj( $obj, $title = '' ) { 206 /***207 * Capture obj to safe HTML string for subsequent printing208 ***/209 206 if ( ! self::cfg('mode_debug') ) return; 210 207 ob_start(); … … 230 227 } 231 228 protected static function GetChnKey() { 232 /*******************************************************************233 * Select key from wp_options table if not already in config (cfg).234 * Fetch subkeys from plugin service if missing or invalid.235 ******************************************************************/236 229 if ( self::cfg('chn_key') 237 && self::cfg('chn_key')['key'] 238 && self::cfg('chn_key')['chn_id'] 239 && self::cfg('chn_key')['key_name'] 230 && self::cfg('chn_key')['key'] 231 && self::cfg('chn_key')['chn_id'] 232 && self::cfg('chn_key')['key_name'] 233 && !self::cfg('chn_key')['error'] 240 234 ) 241 235 return true; … … 264 258 } 265 259 protected static function keyChk() { 266 /********************************************************267 * Fech API-key subkeys from plugin service,268 * store in wp_options table, and set cfg('chn_key'),269 * else store error and set cfg('err').270 *******************************************************/271 260 $url = self::cfg('key_check_url'); 272 261 $arr = [ -
uqrate/trunk/class.sync.php
r2786655 r2789063 192 192 if ( $x->error ) self::errWrap($x->error, __FUNCTION__ ); 193 193 self::cfg()['exit'] = 4000; 194 if ( $code == 424 ) self::keyChk(); 194 195 return false; 195 196 } -
uqrate/trunk/readme.txt
r2786655 r2789063 10 10 License URI: https://www.gnu.org/licenses/gpl-2.0.html 11 11 12 Member-curated comments, paid subscriptions and broadcasting services. [Uqrate.org](https://uqrate.org) is all about generatingrevenue streams for content creators.12 Member-curated comments, paid subscriptions and referrals, and broadcasting. This plugin is designed to generate revenue streams for content creators. 13 13 14 14 == Description == … … 24 24 == Installation == 25 25 26 Add the Uqrate plugin, either from here or by upload (downloaded from [Uqrate.org](https://uqrate.org/app/install#wordpress)). Then activate it and enter your [Uqrate API key](https://uqrate.org/app/apikey). Done. 26 = Install From WordPress.org = 27 28 1. Add the plugin from your Dashboard's **Plugins** > **Add New** menu by Keyword search for `uqrate`. Select **Install**. 29 1. From the Plugins page, select **Activate** under the plugin name. 30 1. At the Dashboard's **Settings** > **Uqrate**, enter your [Uqrate API key](https://uqrate.org/app/apikey). 31 32 = Install From Uqrate.org = 33 34 1. Downloaded the plugin from [Uqrate](https://uqrate.org/app/install#wordpress). 35 1. Upload it at your WordPress Dashboard under **Plugins** > **Add New** page using the **Upload Plugin** button. 36 1. Follow steps 2 and 3 of the WordPress.org procdure (above). 37 38 = Uqrate API Key = 39 40 1. [Login](https://uqrate.org/app/login) or [Signup](https://uqrate.org/app/signup) to your Uqrate account. 41 1. [Add a channel](https://uqrate.org/app/channel) to associate with your blog. 42 1. [Get API Key](https://uqrate.org/app/apikey). Copy/paste it into the form provided at the **Settings** > **Uqrate** page of your WordPress Dashboard menu. 43 44 The plugin requires this secret API key to access Uqrate services. 27 45 28 46 = Minimum Requirements = … … 46 64 == Screenshots == 47 65 66 1. Plugin setup 67 2. Plugin settings 68 3. Comments section (collapsed) 69 4. Comments section (expanded) 70 5. Modal : Subscribe to channel : Initial View 71 6. Modal : Subscribe to channel : Selected Amount 72 7. Modal : Sponsor channel : Other Amount 73 8. Modal : Sponsor message : Initial View 74 48 75 == Changelog == 49 76 50 77 = 1.0.0 = 51 78 52 *Release Date - 1 3September 2022*79 *Release Date - 15 September 2022* 53 80 54 81 * The first release. -
uqrate/trunk/uqrate.php
r2786671 r2789063 29 29 define( 'UQRATE_PLUGIN_PATH', plugin_dir_path( __FILE__ ) ); 30 30 $_UQRATE_ENV = [ 31 'build' => "2022-09- 18T22.51.30Z",31 'build' => "2022-09-22T19.47.58Z", 32 32 'mode_debug' => false, 33 33 'mode_local' => false, -
uqrate/trunk/views/admin.php
r2786655 r2789063 28 28 color: #888; 29 29 } 30 #uqrate_setup_prompt form .description.err { 31 color: #fff; 32 background: #f06; 33 } 30 34 </style> 31 <div id="uqrate_setup_prompt" class="notice notice is-dismissible"> 35 <?php $err = '';if ( Uqrate::cfg('chn_key')['error'] ) { $err = 'notice-error'; } ?> 36 <div id="uqrate_setup_prompt" class="notice <?php echo $err; ?> is-dismissible"> 32 37 <form name="uqrate_activate" action="<?php echo esc_url( Uqrate_Admin::get_page_url( $type ) ); ?>" method="POST"> 33 38 <div class=""> 34 39 <button class="activate" type="submit"><?php _e( 'Setup your', UQRATE_TEXTDOMAIN );?> <span class="uqrate">uqrate</span> <?php _e( 'plugin', UQRATE_TEXTDOMAIN );?></button> 35 40 </div> 41 <?php if ( $err == '' ) : ?> 36 42 <div class="description"> 37 43 Speak your mind, mind your <span class="uqrate">q</span>'s and <span class="uqrate">P</span>'s, and prosper. 38 44 </div> 45 <?php else : ?> 46 <div class="description err"> 47 <?php echo 'Bad API Key'; ?> 48 </div> 49 <?php endif; ?> 39 50 </form> 40 51 </div> … … 55 66 } 56 67 #uqrate_settings .uqrate_setup_footer { 68 display: flex; 69 align-items: center; 70 justify-content: left; 71 } 72 #uqrate_settings .uqrate_setup_footer .build { 73 font-family: monospace; 74 opacity: .5; 75 } 76 #uqrate_settings .uqrate_setup_footer .uqrate_logo { 57 77 display: none; 58 align-items: center;59 justify-content: right;60 78 } 61 79 #uqrate_settings .uqrate_settings_header h2 { 62 margin: .5em 0 . 3em 0;80 margin: .5em 0 .1em 0; 63 81 } 64 82 #uqrate_settings .uqrate_settings_header h2, … … 73 91 color: #af9e06; 74 92 } 93 #uqrate_settings .uqrate_settings_header .build { 94 display: none; 95 font-size: .8em; 96 font-family: monospace; 97 opacity: .7; 98 } 75 99 #uqrate_settings .uqrate_logo { 76 100 width: 8em; … … 141 165 font-size: 2em; 142 166 } 167 #uqrate_settings_block input[name="submit"]:focus { 168 opacity: .9; 169 } 143 170 #uqrate_settings_block form table th { 144 171 width: 7em; … … 178 205 <div class="uqrate_settings_header"> 179 206 <h2> 180 <span class="uqrate">u<strong>q</strong>rate</span> 181 <?php if ( Uqrate::GetCfg('chn_key') ) { echo 'Settings'; } else { echo 'Setup';} ?> 207 <span> 208 <span class="uqrate">u<strong>q</strong>rate</span> 209 <?php 210 if ( Uqrate::GetCfg('chn_key') ) { echo 'Settings'; } else { echo 'Setup';} 211 if ( self::GetCfg('err') ) { 212 echo self::notice_err( 'Try page reload, else get new key : ERR : ' . self::cfg('err') ); 213 } 214 ?> 215 </span> 182 216 </h2> 183 217 <!-- 184 218 <h2>Uqrate Settings</h2> 185 219 --> 220 <h5 class="build"> 221 v<?php echo esc_html( Uqrate::GetCfg('plugin_version') .' '. Uqrate::GetCfg('build') );?> 222 </h5> 186 223 </div> 187 224 <div id="uqrate_setup" class="<?php if ( Uqrate::GetCfg('chn_key') ) echo 'hide'; ?>"> … … 247 284 <dd class=""> 248 285 <table class="<?php if ( ! Uqrate::GetCfg('chn_key') ) echo 'hide'; ?>"> 286 <tr class="hide"> 287 <td class="key">version:</td> 288 <td class="val">v<?php echo esc_html( Uqrate::GetCfg('plugin_version') .' '. Uqrate::GetCfg('build') ); ?></td> 289 </tr> 249 290 <tr class=""> 250 291 <td class="key">key:</td> … … 323 364 </div> 324 365 <div class="uqrate_setup_footer"> 366 <div class="build"> 367 uqrate plugin v<?php 368 echo esc_html( Uqrate::GetCfg('plugin_version') 369 .' build ' 370 . Uqrate::GetCfg('build') ); 371 ?> 372 </div> 325 373 <div class="uqrate_logo"> 326 374 <!-- -
uqrate/trunk/views/css/a.settings.css
r2786655 r2789063 44 44 opacity: .7; 45 45 } 46 47 /*48 Fallback when CSP forbids inline CSS49 */50 51 52 #uqrate_settings .uqrate {53 color: #664;54 opacity: .8;55 }56 57 #uqrate_settings h1 {58 display: none;59 }60 #uqrate_settings .uqrate_settings_header {61 display: flex;62 align-items: center;63 justify-content: space-between;64 }65 #uqrate_settings .uqrate_setup_footer {66 display: none;67 align-items: center;68 justify-content: right;69 }70 71 #uqrate_settings .uqrate_settings_header h2 {72 margin: .5em 0 .3em 0;73 }74 #uqrate_settings .uqrate_settings_header h2,75 #uqrate_settings .uqrate_settings_header h2 span.uqrate {76 font-size: 3rem;77 font-weight: bold;78 color: #330;79 line-height: 1.2em;80 opacity: 1;81 }82 #uqrate_settings .uqrate_settings_header h2 span.uqrate strong {83 color: #af9e06;84 }85 #uqrate_settings .uqrate_logo {86 width: 8em;87 height: 8em;88 fill: #c6b305;89 }90 91 #uqrate_settings .button {92 font-size: 2em;93 border-radius: .5em;94 box-shadow: .1em .1em .2em rgba(0, 0, 0, 0.3); /* x, y, blur */95 }96 #uqrate_settings .button:active {97 opacity: .9;98 }99 100 #uqrate_settings dl {101 display: flex;102 align-items: center;103 margin-bottom: 2em;104 flex-wrap: wrap;105 }106 107 #uqrate_settings dl dt {108 font-size: 3em;109 padding: .7em;110 background:#c6b305;111 border-radius: 50%;112 }113 114 #uqrate_settings dd .button {115 width: 8em;116 text-align: center;117 }118 #uqrate_settings_block input.button {119 width: 8em; /* keep uniform */120 }121 #uqrate_settings dd.info{122 font-size: 1.2em;123 max-width: 30em;124 margin: 1em 0 1.5em 2em;125 }126 127 /** $title @ add_settings_section(..) */128 129 #uqrate_settings_block dd {130 width: 100%;131 margin: 0;132 }133 134 #uqrate_settings_block form {135 margin: 0;136 }137 138 #uqrate_setup dd.link,139 #uqrate_setup dd.info {140 padding-top: .2em;141 }142 143 #uqrate_setup a.button,144 #uqrate_settings_update a.button {145 height: auto;146 padding: .4em;147 }148 149 150 #uqrate_settings_block input[name="uqrate_chnkey_key"] {151 height: auto;152 width: 100%;153 font-size: .8em;154 font-family: monospace;155 color: #999;156 padding: .5em .4em .5em .4em;157 max-width: 53em;158 }159 #uqrate_settings_block input[name="submit"] {160 height: auto;161 padding: .4em;162 font-size: 2em;163 }164 #uqrate_settings_block input[name="submit"]:focus {165 opacity: .9;166 }167 #uqrate_settings_block form table th {168 width: 7em;169 font-size: 2em;170 color: #330;171 }172 173 /** status **/174 175 #uqrate_status_block dd {176 margin: 0;177 padding: 0;178 }179 #uqrate_status_block table td.key {180 font-family: monospace;181 width: 7em;182 text-align: right;183 padding-right: .7em;184 }185 #uqrate_status_block table td.val {186 font-family: monospace;187 min-width: 20em;188 text-align: left;189 padding-right: .7em;190 }191 #uqrate_status_block table td .warn {192 text-align: left;193 color: #f06;194 font-weight: bold;195 padding-left: 2em;196 }197 #uqrate_status_block table td .warn a,198 #uqrate_status_block table tr.warn td.key {199 color: #f06;200 }
Note: See TracChangeset
for help on using the changeset viewer.