Coder Social home page Coder Social logo

hmayer00 / planbox-feedback-widget Goto Github PK

View Code? Open in Web Editor NEW

This project forked from martindrapeau/planbox-feedback-widget

1.0 0.0 0.0 140 KB

Widget to capture User Feedback on your site. Manage it inside Planbox.

Home Page: www.planbox.com

JavaScript 100.00%

planbox-feedback-widget's Introduction

Widget you can embed on your site to capture user feedback.
Saves the User Feedback in Planbox.
Planbox docs: http://www.planbox.com/help/user_feedback


FEATURES
- Supports any localization simply by settings options in global variable FeedbackOptions.
- Style it any way you want by modifying the CSS file feedback.css.
- Uses JSONP to call the Planbox REST API 


REQUIREMENTS
- You need jQuery 1.5+


INSTALLATION
1) Copy feedback.js and feedback.css on your site.

2) Include them in your HTML document like this:
  <link href="/js/feedback/feedback.css" rel="stylesheet" type="text/css" charset="utf-8" />
  <script src="/js/feedback/feedback.js" type="text/javascript"></script>

3) Configure options:
  <script type="text/javascript">
    FeedbackOptions.planboxToken = '123hshdajh2galvnmxnwhruyfhdj';
    FeedbackOptions.dialogTitle = 'Tell us what you think';
  </script>

4) Modify feedback.css to suit your design style.

Note: Files are also hosted on www.planbox.com. You can load them like this as well:
  <link href="http://www.planbox.com/feedback/feedback.css" rel="stylesheet" type="text/css" charset="utf-8" />
  <script src="http://www.planbox.com/feedback/feedback.js" type="text/javascript"></script>


OPTIONS
  // You can find your Planbox initiative token on the Manage page
  // Instructions: http://www.planbox.com/help/user_feedback
  planboxToken: '<TOKEN>',
  
  // You can forward any incoming feedback to an email
  // Keep empty not to. Only a single email is allowed.
  forwardEmail: '',
  	
  // You can set the page URL. If empty will use window.location.href
  pageUrl: '',
  
  // You can specify a human readable page title
  pageTitle: '',
  
  // The button appears center-left by default. Modify in CSS.
  // It is an image you can modify here.
  // If you want your own custom button, set showButton to false.
  // You can then call function FeedbackShow().
  showButton: true,
  buttonImageSrc: protocol+'://www.planbox.com/img/feedback_button.png',
  buttonImageAlt: 'Feedback',
  buttonTooltip: 'Send us Feedback',
  
  // When you click on the button it opens a dialog
  dialogTitle: 'User Feedback',
  dialogCloseTooltip: 'Close dialog',
  dialogEmailLabel: 'Your email',
  dialogFeedbackLabel: 'Your feedback',
  dialogCancelText: 'Cancel',
  dialogSubmitText: 'Submit',
  dialogCloseText: 'Close',
  
  // You can prefill the email
  dialogEmail: '',

  // When the user clicks on Submit, do some validation
  // and tell the user what's happening
  emailIsRequired: true,
  emailInvalidError: 'Please provide a valid email',
  feedbackMissingError: 'Please type in feedback',
  feedbackAjaxSuccess: 'We have received your feedback. Thank you!',
  feedbackAjaxError: 'There was an error.',

  // When the user opens the window
  // The dialog element is passed as argument
  onshow: function(){},

  // When the user closes the window, but before the window is destroyed.
  // The dialog element is passed as argument
  beforehide: function(){},

  // Deprecated...

  // When the user opens the window
  // The jQuery content element is passed as argument
  callback: function(){}

FUNCTIONS:
  // If you have your own custom button, call this function to
  // open the Feedback dialog.
  FeedbackShow()
	
Author: Martin Drapeau
Copyright: Planbox Inc. 2011
License: MIT License (http://en.wikipedia.org/wiki/MIT_License)

planbox-feedback-widget's People

Contributors

pierre-alain avatar apinstein avatar hmayer00 avatar

Stargazers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.