Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Q
question2answer
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
outils
question2answer
Commits
59ad6e0a
Commit
59ad6e0a
authored
Dec 02, 2014
by
Scott
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Coding style (default plugins)
parent
9b5766d2
Show whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
89 additions
and
270 deletions
+89
-270
qa-basic-adsense.php
qa-plugin/basic-adsense/qa-basic-adsense.php
+12
-21
qa-plugin.php
qa-plugin/basic-adsense/qa-plugin.php
+3
-9
qa-event-logger.php
qa-plugin/event-logger/qa-event-logger.php
+3
-10
qa-plugin.php
qa-plugin/event-logger/qa-plugin.php
+3
-9
qa-example-lang-default.php
qa-plugin/example-page/qa-example-lang-default.php
+2
-8
qa-example-lang-en-GB.php
qa-plugin/example-page/qa-example-lang-en-GB.php
+2
-8
qa-example-page.php
qa-plugin/example-page/qa-example-page.php
+3
-10
qa-plugin.php
qa-plugin/example-page/qa-plugin.php
+4
-10
qa-facebook-layer.php
qa-plugin/facebook-login/qa-facebook-layer.php
+4
-10
qa-facebook-login-page.php
qa-plugin/facebook-login/qa-facebook-login-page.php
+3
-9
qa-facebook-login.php
qa-plugin/facebook-login/qa-facebook-login.php
+3
-11
qa-plugin.php
qa-plugin/facebook-login/qa-plugin.php
+5
-10
qa-mouseover-admin-form.php
qa-plugin/mouseover-layer/qa-mouseover-admin-form.php
+3
-10
qa-mouseover-layer.php
qa-plugin/mouseover-layer/qa-mouseover-layer.php
+3
-10
qa-plugin.php
qa-plugin/mouseover-layer/qa-plugin.php
+4
-10
qa-opensearch-layer.php
qa-plugin/opensearch-support/qa-opensearch-layer.php
+3
-10
qa-opensearch-page.php
qa-plugin/opensearch-support/qa-opensearch-page.php
+3
-10
qa-plugin.php
qa-plugin/opensearch-support/qa-plugin.php
+4
-10
qa-plugin.php
qa-plugin/recaptcha-captcha/qa-plugin.php
+3
-9
qa-recaptcha-captcha.php
qa-plugin/recaptcha-captcha/qa-recaptcha-captcha.php
+3
-16
qa-plugin.php
qa-plugin/tag-cloud-widget/qa-plugin.php
+3
-9
qa-tag-cloud.php
qa-plugin/tag-cloud-widget/qa-tag-cloud.php
+3
-10
qa-plugin.php
qa-plugin/wysiwyg-editor/qa-plugin.php
+4
-10
qa-wysiwyg-editor.php
qa-plugin/wysiwyg-editor/qa-wysiwyg-editor.php
+0
-6
qa-wysiwyg-upload.php
qa-plugin/wysiwyg-editor/qa-wysiwyg-upload.php
+0
-6
qa-plugin.php
qa-plugin/xml-sitemap/qa-plugin.php
+3
-9
qa-xml-sitemap.php
qa-plugin/xml-sitemap/qa-xml-sitemap.php
+3
-10
No files found.
qa-plugin/basic-adsense/qa-basic-adsense.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_basic_adsense
{
class
qa_basic_adsense
{
public
function
allow_template
(
$template
)
{
return
(
$template
!=
'admin'
);
...
...
@@ -89,24 +89,16 @@
?>
<div
style=
"
<?php
echo
$divstyle
?>
"
>
<script
type=
"text/javascript"
>
google_ad_client
=
<?php
echo
qa_js
(
qa_opt
(
'adsense_publisher_id'
))
?>
;
google_ad_width
=
<?php
echo
qa_js
(
$width
)
?>
;
google_ad_height
=
<?php
echo
qa_js
(
$height
)
?>
;
google_ad_format
=
<?php
echo
qa_js
(
$format
)
?>
;
google_ad_type
=
"text_image"
;
google_ad_channel
=
""
;
</script>
<script
type=
"text/javascript"
src=
"http://pagead2.googlesyndication.com/pagead/show_ads.js"
>
</script>
<script
type=
"text/javascript"
>
google_ad_client
=
<?php
echo
qa_js
(
qa_opt
(
'adsense_publisher_id'
))
?>
;
google_ad_width
=
<?php
echo
qa_js
(
$width
)
?>
;
google_ad_height
=
<?php
echo
qa_js
(
$height
)
?>
;
google_ad_format
=
<?php
echo
qa_js
(
$format
)
?>
;
google_ad_type
=
"text_image"
;
google_ad_channel
=
""
;
</script>
<script
type=
"text/javascript"
src=
"http://pagead2.googlesyndication.com/pagead/show_ads.js"
></script>
</div>
<?php
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/basic-adsense/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,15 +34,10 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_module
(
'widget'
,
'qa-basic-adsense.php'
,
'qa_basic_adsense'
,
'Basic AdSense'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_module
(
'widget'
,
'qa-basic-adsense.php'
,
'qa_basic_adsense'
,
'Basic AdSense'
);
qa-plugin/event-logger/qa-event-logger.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_event_logger
{
class
qa_event_logger
{
public
function
init_queries
(
$table_list
)
{
if
(
qa_opt
(
'event_logger_to_database'
))
{
...
...
@@ -228,10 +228,4 @@
}
}
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/event-logger/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,15 +34,10 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_module
(
'event'
,
'qa-event-logger.php'
,
'qa_event_logger'
,
'Event Logger'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_module
(
'event'
,
'qa-event-logger.php'
,
'qa_event_logger'
,
'Event Logger'
);
qa-plugin/example-page/qa-example-lang-default.php
View file @
59ad6e0a
...
...
@@ -20,11 +20,6 @@
More about this license: http://www.question2answer.org/license.php
*/
return
array
(
return
array
(
'page_title'
=>
'Example plugin page (US English)'
,
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
);
qa-plugin/example-page/qa-example-lang-en-GB.php
View file @
59ad6e0a
...
...
@@ -20,11 +20,6 @@
More about this license: http://www.question2answer.org/license.php
*/
return
array
(
return
array
(
'page_title'
=>
'Example plugin page (UK English)'
,
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
);
qa-plugin/example-page/qa-example-page.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_example_page
{
class
qa_example_page
{
private
$directory
;
private
$urltoroot
;
...
...
@@ -95,10 +95,4 @@
return
$qa_content
;
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/example-page/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,16 +34,11 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_module
(
'page'
,
'qa-example-page.php'
,
'qa_example_page'
,
'Example Page'
);
qa_register_plugin_phrases
(
'qa-example-lang-*.php'
,
'example_page'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_module
(
'page'
,
'qa-example-page.php'
,
'qa_example_page'
,
'Example Page'
);
qa_register_plugin_phrases
(
'qa-example-lang-*.php'
,
'example_page'
);
qa-plugin/facebook-login/qa-facebook-layer.php
View file @
59ad6e0a
...
...
@@ -20,23 +20,18 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_html_theme_layer
extends
qa_html_theme_base
{
class
qa_html_theme_layer
extends
qa_html_theme_base
{
public
function
head_css
()
{
qa_html_theme_base
::
head_css
();
if
(
strlen
(
qa_opt
(
'facebook_app_id'
))
&&
strlen
(
qa_opt
(
'facebook_app_secret'
)))
if
(
strlen
(
qa_opt
(
'facebook_app_id'
))
&&
strlen
(
qa_opt
(
'facebook_app_secret'
)))
{
$this
->
output
(
'<style>'
,
'.fb-login-button.fb_iframe_widget.fb_hide_iframes span {display:none;}'
,
'</style>'
);
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/facebook-login/qa-facebook-login-page.php
View file @
59ad6e0a
...
...
@@ -20,7 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_facebook_login_page
{
class
qa_facebook_login_page
{
private
$directory
;
private
$urltoroot
;
...
...
@@ -83,10 +84,4 @@
qa_redirect_raw
(
$tourl
);
}
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/facebook-login/qa-facebook-login.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_facebook_login
{
class
qa_facebook_login
{
public
function
match_source
(
$source
)
{
return
$source
==
'facebook'
;
...
...
@@ -82,7 +82,6 @@
</script>
<div
class=
"fb-login-button"
style=
"display:inline; vertical-align:middle;"
size=
"
<?php
echo
$size
?>
"
<?php
echo
$logout
?
'autologoutlink="true"'
:
'scope="email,user_about_me,user_location,user_website"'
?>
>
</div>
<?php
}
...
...
@@ -126,10 +125,4 @@
),
);
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/facebook-login/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -35,19 +35,15 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
if
(
!
QA_FINAL_EXTERNAL_USERS
)
{
// login modules don't work with external user integration
// login modules don't work with external user integration
if
(
!
QA_FINAL_EXTERNAL_USERS
)
{
qa_register_plugin_module
(
'login'
,
'qa-facebook-login.php'
,
'qa_facebook_login'
,
'Facebook Login'
);
qa_register_plugin_module
(
'page'
,
'qa-facebook-login-page.php'
,
'qa_facebook_login_page'
,
'Facebook Login Page'
);
qa_register_plugin_layer
(
'qa-facebook-layer.php'
,
'Facebook Login Layer'
);
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/mouseover-layer/qa-mouseover-admin-form.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_mouseover_admin_form
{
class
qa_mouseover_admin_form
{
public
function
option_default
(
$option
)
{
if
(
$option
===
'mouseover_content_max_len'
)
...
...
@@ -71,10 +71,4 @@
),
);
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/mouseover-layer/qa-mouseover-layer.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_html_theme_layer
extends
qa_html_theme_base
{
class
qa_html_theme_layer
extends
qa_html_theme_base
{
public
function
q_list
(
$q_list
)
{
if
(
!
empty
(
$q_list
[
'qs'
])
&&
qa_opt
(
'mouseover_content_on'
))
{
// first check it is not an empty list and the feature is turned on
...
...
@@ -63,10 +63,4 @@
qa_html_theme_base
::
q_list
(
$q_list
);
// call back through to the default function
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/mouseover-layer/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,16 +34,11 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_layer
(
'qa-mouseover-layer.php'
,
'Mouseover Layer'
);
qa_register_plugin_module
(
'module'
,
'qa-mouseover-admin-form.php'
,
'qa_mouseover_admin_form'
,
'Mouseover Layer'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_layer
(
'qa-mouseover-layer.php'
,
'Mouseover Layer'
);
qa_register_plugin_module
(
'module'
,
'qa-mouseover-admin-form.php'
,
'qa_mouseover_admin_form'
,
'Mouseover Layer'
);
qa-plugin/opensearch-support/qa-opensearch-layer.php
View file @
59ad6e0a
...
...
@@ -20,18 +20,12 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_html_theme_layer
extends
qa_html_theme_base
{
class
qa_html_theme_layer
extends
qa_html_theme_base
{
public
function
head_links
()
{
qa_html_theme_base
::
head_links
();
$this
->
output
(
'<link rel="search" type="application/opensearchdescription+xml" title="'
.
qa_html
(
qa_opt
(
'site_title'
))
.
'" href="'
.
qa_path_html
(
'opensearch.xml'
)
.
'"/>'
);
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/opensearch-support/qa-opensearch-page.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_opensearch_xml
{
class
qa_opensearch_xml
{
public
function
match_request
(
$request
)
{
return
(
$request
==
'opensearch.xml'
);
...
...
@@ -48,10 +48,4 @@
return
null
;
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/opensearch-support/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,16 +34,11 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_layer
(
'qa-opensearch-layer.php'
,
'OpenSearch Layer'
);
qa_register_plugin_module
(
'page'
,
'qa-opensearch-page.php'
,
'qa_opensearch_xml'
,
'OpenSearch XML'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_layer
(
'qa-opensearch-layer.php'
,
'OpenSearch Layer'
);
qa_register_plugin_module
(
'page'
,
'qa-opensearch-page.php'
,
'qa_opensearch_xml'
,
'OpenSearch XML'
);
qa-plugin/recaptcha-captcha/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,15 +34,10 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_module
(
'captcha'
,
'qa-recaptcha-captcha.php'
,
'qa_recaptcha_captcha'
,
'reCAPTCHA'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_module
(
'captcha'
,
'qa-recaptcha-captcha.php'
,
'qa_recaptcha_captcha'
,
'reCAPTCHA'
);
qa-plugin/recaptcha-captcha/qa-recaptcha-captcha.php
View file @
59ad6e0a
...
...
@@ -20,14 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../'
);
exit
;
}
class
qa_recaptcha_captcha
{
class
qa_recaptcha_captcha
{
private
$directory
;
public
function
load_module
(
$directory
,
$urltoroot
)
...
...
@@ -139,10 +133,4 @@
return
false
;
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/tag-cloud-widget/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,15 +34,10 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_module
(
'widget'
,
'qa-tag-cloud.php'
,
'qa_tag_cloud'
,
'Tag Cloud'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_module
(
'widget'
,
'qa-tag-cloud.php'
,
'qa_tag_cloud'
,
'Tag Cloud'
);
qa-plugin/tag-cloud-widget/qa-tag-cloud.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_tag_cloud
{
class
qa_tag_cloud
{
public
function
option_default
(
$option
)
{
if
(
$option
===
'tag_cloud_count_tags'
)
...
...
@@ -141,10 +141,4 @@
$themeobject
->
output
(
'</div>'
);
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
qa-plugin/wysiwyg-editor/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,16 +34,11 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_module
(
'editor'
,
'qa-wysiwyg-editor.php'
,
'qa_wysiwyg_editor'
,
'WYSIWYG Editor'
);
qa_register_plugin_module
(
'page'
,
'qa-wysiwyg-upload.php'
,
'qa_wysiwyg_upload'
,
'WYSIWYG Upload'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_module
(
'editor'
,
'qa-wysiwyg-editor.php'
,
'qa_wysiwyg_editor'
,
'WYSIWYG Editor'
);
qa_register_plugin_module
(
'page'
,
'qa-wysiwyg-upload.php'
,
'qa_wysiwyg_upload'
,
'WYSIWYG Upload'
);
qa-plugin/wysiwyg-editor/qa-wysiwyg-editor.php
View file @
59ad6e0a
...
...
@@ -245,8 +245,3 @@ class qa_wysiwyg_editor
return
qa_html
(
number_format
(
$bytes
/
1048576
,
1
));
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa-plugin/wysiwyg-editor/qa-wysiwyg-upload.php
View file @
59ad6e0a
...
...
@@ -56,8 +56,3 @@ class qa_wysiwyg_upload
return
null
;
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa-plugin/xml-sitemap/qa-plugin.php
View file @
59ad6e0a
...
...
@@ -34,15 +34,10 @@
*/
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
if
(
!
defined
(
'QA_VERSION'
))
{
// don't allow this page to be requested directly from browser
header
(
'Location: ../../'
);
exit
;
}
}
qa_register_plugin_module
(
'page'
,
'qa-xml-sitemap.php'
,
'qa_xml_sitemap'
,
'XML Sitemap'
);
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
qa_register_plugin_module
(
'page'
,
'qa-xml-sitemap.php'
,
'qa_xml_sitemap'
,
'XML Sitemap'
);
qa-plugin/xml-sitemap/qa-xml-sitemap.php
View file @
59ad6e0a
...
...
@@ -20,8 +20,8 @@
More about this license: http://www.question2answer.org/license.php
*/
class
qa_xml_sitemap
{
class
qa_xml_sitemap
{
private
$directory
;
private
$urltoroot
;
...
...
@@ -288,10 +288,4 @@
"
\t\t
<priority>"
.
max
(
0
,
min
(
1.0
,
$priority
))
.
"</priority>
\n
"
.
"
\t
</url>
\n
"
;
}
}
/*
Omit PHP closing tag to help avoid accidental output
*/
\ No newline at end of file
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment