AdMob Plugin Request

Post your work in progress addons and get feedback

Post » Sun Mar 31, 2013 8:09 am

Hey,
Please make a plugin for admob by which we can ad ads easily without having to copy the code and other difficult things i don't know
B
7
Posts: 1
Reputation: 384

Post » Sun Nov 03, 2013 11:06 pm

i am with you in this, its really painful to do !!
B
24
S
4
G
2
Posts: 45
Reputation: 2,403

Post » Mon Nov 04, 2013 12:35 am

i am author of Phonegap plugin. (http://www.scirra.com/forum/topic74901.html)

i can create the plugin called PhonegapAD if you help me.

without use of activity.root member (root is not public member, so compile error occurs)
use other activity's member and get layout

in "REPLACE THIS CODE" line, what other code you can put?

      adView = new AdView(activity, AdSize.BANNER, "a1503e07f0254b1");
                    
      LinearLayout layout = activity.root;//compile error//REPLACE THIS CODE

      layout.addView(adView);//bottom

      layout.setHorizontalGravity(android.view.Gravity.CENTER_HORIZONTAL);

      AdRequest request = new AdRequest();

      adView.loadAd(request);

cranberrygame2013-11-04 01:38:46
B
57
S
19
G
79
Posts: 770
Reputation: 45,109

Post » Mon Nov 04, 2013 12:56 pm

[QUOTE=cranberrygame] i am author of Phonegap plugin. (http://www.scirra.com/forum/topic74901.html)

i can create the plugin called PhonegapAD if you help me.

without use of activity.root member (root is not public member, so compile error occurs)
use other activity's member and get layout

in "REPLACE THIS CODE" line, what other code you can put?

      adView = new AdView(activity, AdSize.BANNER, "a1503e07f0254b1");
                    
      LinearLayout layout = activity.root;//compile error//REPLACE THIS CODE

      layout.addView(adView);//bottom

      layout.setHorizontalGravity(android.view.Gravity.CENTER_HORIZONTAL);

      AdRequest request = new AdRequest();

      adView.loadAd(request);

[/QUOTE]
it would be nice if you can do it , but i have no clue in coding
B
24
S
4
G
2
Posts: 45
Reputation: 2,403

Post » Mon Nov 04, 2013 4:20 pm

@asmina22

i tried to create PhonegapAD plugin.

but that blocked me.

if that solved, the plugin you want will come out.

welcome to scirra.
B
57
S
19
G
79
Posts: 770
Reputation: 45,109

Post » Mon Feb 17, 2014 12:46 pm

@cranberrygame,

maybe you can use:
LinearLayout layout = (LinearLayout)findViewById(R.id.mainLayout);

i got the code from this link:
https://developers.google.com/mobile-ads-sdk/docs/admob/fundamentals
B
3
Posts: 20
Reputation: 207

Post » Thu Feb 20, 2014 1:48 pm

@gamesura

i checked your code but runtime error occurred.

very thank you.

p.s even not plugin, if you can replace "REPLACE THIS CODE" to something in main java file, send to me that code.
i'll apply that code.

adView = new AdView(activity, AdSize.BANNER, "a1503e07f0254b1");

LinearLayout layout = activity.root;//compile error//REPLACE THIS CODE

layout.addView(adView);//bottom

layout.setHorizontalGravity(android.view.Gravity.CENTER_HORIZONTAL);

AdRequest request = new AdRequest();

adView.loadAd(request);
B
57
S
19
G
79
Posts: 770
Reputation: 45,109

Post » Thu Jun 19, 2014 8:04 pm

c2 phonegap admob plugin released!
come to plugin-phonegap-admob_t108644
B
57
S
19
G
79
Posts: 770
Reputation: 45,109


Return to Work in Progress Addons

Who is online

Users browsing this forum: No registered users and 1 guest